Jump to content

ileonemil

Member
  • Posts

    15
  • Joined

  • Last visited

Posts posted by ileonemil

  1. 4 hours ago, vitor said:

    @ileonemil Please follow these instructions, as the first pot asks. 

    Thank you and sorry. These are the following:

    • Brew command not found (I'm on MacBook Pro M1)
    • v21.13
    • Alfred 4.6.1
    • MacOS Monterey 12.0.1
    • Every link since the problem is the keyword
    • [09:47:59.384] Logging Started...
      [09:50:36.934] DownMedia[Script Filter] Queuing argument ''
      [09:50:37.151] DownMedia[Script Filter] Script with argv '' finished
      [09:50:37.153] ERROR: DownMedia[Script Filter] Code 1: Did not find "yt-dlp". You will need to install it yourself. Homebrew recommended.
      
      Alternatively, download an older version of this Workflow without the dependency: https://github.com/vitorgalvao/alfred-workflows/tree/c0d9c9313857676997e6e05d9dda65cfa5fcda6a/DownMedia
      
      Keep in mind that is no longer supported. It will continue to work until the (discontinued) youtube-dl no longer does.

       

     

  2. 1 minute ago, deanishe said:

     

    That's a pretty weird way to do it, tbh. If the script runs in your shell, you should generally be able to get it to run in Alfred by specifying the absolute paths and possibly setting a few environment variables.

     

    Yeah I'll try. I did that because the script uses two apis from different services and have to interact with another script to have some credentials. That way I only put that string before it so that I don't have to change nothing. Thank you very much!!! Have a good day :)

  3. 2 hours ago, deanishe said:

     

    You should put your Python scripts in the workflow directory and install dependencies alongside them using pip’s --target flag, e.g. cd to the workflow folder (or right-click on the workflow in Alfred and choose Open in Terminal), then run /usr/bin/python -m pip install --target . package-name other-package-name

     

     

    It sounds like you’ve installed a custom Python (with Homebrew at /usr/local/bin/python3).

     

    Alfred doesn’t use your shell environment, so it doesn’t have your custom PATH etc.

     

    The command python3 in Alfred always runs /usr/bin/python3. Make sure you’re running /usr/bin/python3 when testing your workflow script in a shell. Similarly, when you have multiple Pythons, you never know which one pip is connected to.

     

    It’s a very good habit to run pip as /path/to/python -m pip

     

    -m tells Python to run an installed library (it runs the __main__.py file if there is one), and a lot of command-line tools can be run this way. If you always run pip that way, you’ll always install the right version of a library in the right place.

     

    Firstly thank you very much. I finally managed to do that in another way last night. I chose 'run script' and put it in bash, then I wrote this /usr/local/bin/python3 <<'EOF' - "$@" and pasted all the script next to it. That's a very long script but it seems all okay :). Is it right? Thanks anyway for your super helpful tips, will use them for sure. Have a good day!

  4. On 6/25/2021 at 5:10 PM, vitor said:

     

    That’s why it isn’t working. Alfred doesn’t load your shell environment, so it won’t know about PYTHONPATH, or pyenv, or whatever you’re doing in your shell’s startup files to make your packages available. Whatever you’re doing there, you have to redo in Alfred’s Run Script. Think of it like the Terminal of a freshly installed macOS—there’s no configuration or customisation done, so you have to make sure to first load what you need.

     

    Open the debugger, set the log output to “All Information”, perfom the failing action, and you’ll see exactly what’s wrong.

     

    Thank you, is there a way to download Python modules so? I tried to open the directory of the workflow with Terminal, but pip said that the package was already installed....from the debugger I see that's not true so I think that I have to download the module in another place....Where?How?

  5. 7 hours ago, wrjlewis said:

     

    Can you explain in more detail what happens when you press enter on a search result in Alfred? 
    Do you receive any errors? Does it open a web browser (or notion app if you have that configured) with the result?

     

    Hi, now I understand. I put the variable that makes the searched page opening in the desktop app to true, but it function only if Notion is closed, because it opens a new Notion window with the searched page. Is someway possible to use the workflow having Notion opened?

  6. On 6/17/2021 at 8:50 PM, Pete Bastille said:

    Hello,
    Thank you so much for this workflow, it's a game changer for me ! 

    I currently can't make it work though. I followed the information I found in this thread but I still have the same error message : 

    1239573743_Screenshot2021-06-17at20_48_50.thumb.png.d8aa495cb726f0a136eea327f423be9f.png

     

    Does anyone know how to fix this ? 

    Thank you ! 

    Pete

    I think you didn't put the right token on the variables 

×
×
  • Create New...