Jump to content

Making Python 2 Workflows work on macOS Monterey 12.3 and above

Recommended Posts

2 minutes ago, vitor said:

That doesn’t look like it needs fixing. Just following the instructions to reinstall Python 2 should do it. It is possible that Google Chrome has changed how it stores passwords in the meantime.


My bad, I thought it was the purpose of this initiative (https://github.com/alfredapp/updated-third-party-python2-workflows) and didn't realize I could solve things on my own. I'll give it a try right now


Link to comment
1 minute ago, vitor said:


It is, but you always need to do that part. The second part, where the workflow is updated, is not needed in every case.


All right, thanks for clarifying things. 

One last thing: I don't want to mess up with existing python 3 configuration by reinstalling python 2. 

Can you confirm the only steps to follow are here: https://www.alfredapp.com/help/kb/install-dependencies/

Thanks again

Link to comment
On 2/3/2022 at 11:29 PM, vitor said:


Check the list of available Workflows. If the one you need isn’t present, ask for it there or as a reply on this thread. Be sure to include a link to the original.


Note this is only for Python 2 Workflows which break on Monterey 12.3 and above due to the Python 2 removal. If a Workflow stops working for any other reason, contact the author as usual.

Is it possible to request owner of these Python 2 workflows to see if these can be re-worked to work with Python 3? These are some of the best workflows and it would be great to have them in Python 3 directly.

Link to comment
On 10/13/2022 at 8:55 AM, vitor said:


That just says “TODO” and is left as a pre-release. The only commit is “Hello World” and it has an unsigned app inside. It’s clearly unfinished, so doesn’t fall into scope.


Ok, thx for looking into it. Pity, as it’s such a unique and useful plugin.


Not sure if @Mr Pennyworth still visits these forums but it would be great if he could help update.

Link to comment
  • 2 weeks later...

Hi @vitor, I'm a little late to this thread, but I'm having trouble after upgrading from Big Sur to Monterey 12.6.1 running Alfred 4.8.


None of my Workflows seem to be functioning. For example with the StackOverflow workflow, once I type anything beyond `.so`, Alfred then switches to the Google / Amazon / Wikipedia search options.


For troubleshooting purposes, I'm just testing the following Workflows:

  • Google Suggest
  • StackOverflow
  • Spotify Mini Player


I already had pyenv installed with Homebrew. I installed Python 2 and created a symbolic link with the following commands:

pyenv install 2.7.18
eval "$(brew shellenv)"
ln -s "${HOME}/.pyenv/versions/2.7.18/bin/python2.7" "${HOMEBREW_PREFIX}/bin/python"


My global ~/.pyenv/version is set to 3.10.4. I changed that to 2.7.18 and restarted Alfred to try to get Workflows running but still no luck. I've also installed PHP with Homebrew (for Spotify Mini Player).


I'm on an Intel Mac if that makes any difference.


Can you let me know if there's something I'm missing? Tried digging through this thread history but nothing popped at me.

Link to comment
3 hours ago, tinyearth said:

My global ~/.pyenv/version is set to 3.10.4. I changed that to 2.7.18

That’s not part of the instructions, it doesn’t make a difference.


3 hours ago, tinyearth said:

Google Suggest

Make sure you’re on the latest version of that, which you can install directly within Alfred. That Workflow has never required python.


3 hours ago, tinyearth said:


You have to also install the updated version, as per the top post.


3 hours ago, tinyearth said:

Spotify Mini Player

That’s also not related to this matter, as you’ve noted.


3 hours ago, tinyearth said:

For troubleshooting purposes, I'm just testing the following Workflows:

Testing fewer makes it harder to debug, not simpler.


Look at the debugger. Without that information it is impossible to say what may be going on.

Link to comment

Thank you, the debugger tip was very helpful!


I have everything up and running again. Most of it just involved getting the latest versions (or your mods) of the Workflows.


Apologies if it came across as making debugging complicated. I reached out via email first and was redirected to post here after the Python 2 install didn't resolve my issues and just relayed the same details. Didn't realize that Python wasn't necessarily the underlying dependency involved in every Workflow hiccup.

Link to comment
2 hours ago, tinyearth said:

Apologies if it came across as making debugging complicated.


Not at all, don’t worry about it. I hope my terseness wasn’t misinterpreted either; because there were several points to get through, I tried to do it in the way that would get you on the right path faster, even if that just meant finding the right information for us to be able to help you further. Something in the way you phrased your post made me think you had the experience to do a good followup after the initial pointers, but you did even better! Glad it’s resolved.


Unrelated, I hadn’t noticed before that was your first post to the forum. Welcome!

Link to comment
  • 1 month later...
  • 3 weeks later...

@vitor I get the following error when i try to install python 2 using the below through terminal.


Could you please help. Also, i'm not very familiar with these commands :)



/bin/bash -c "$(curl -fsSL https://github.com/alfredapp/dependency-scripts/raw/main/scripts/install-python2.sh)"


--- terminal extract---

BUILD FAILED (OS X 13.1 using python-build 20180424)

Inspect or clean up the working tree at /var/folders/mm/_zvz6rvx6p766vplb_38_x6c0000gn/T/python-build.20221230073823.8603
Results logged to /var/folders/mm/_zvz6rvx6p766vplb_38_x6c0000gn/T/python-build.20221230073823.8603.log

Last 10 log lines:
checking MACHDEP... darwin
checking for --without-gcc... no
checking for --with-icc... no
checking for gcc... clang
checking whether the C compiler works... no
configure: error: in `/var/folders/mm/_zvz6rvx6p766vplb_38_x6c0000gn/T/python-build.20221230073823.8603/Python-2.7.18':
configure: error: C compiler cannot create executables
See `config.log' for more details
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
ln: /usr/local/bin/python: File exists


---end of terminal extract ---

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...