ipaterson Posted April 14, 2015 Share Posted April 14, 2015 (edited) Any python workflow using locale.getdefaultlocale() will crash in Alfred 2.7 due to an unhandled exception. Since the python docs do not suggest that it is even possible for an exception to be thrown from that function, I do not imagine anyone wrapped this in a try block. I received some bug reports this weekend from some pre-release path folks who were seeing errors about unknown locale: UTF-8. I noticed in the release notes for the latest Alfred that the following change was made: • Add LC_CTYPE=UTF-8 encoding to script environment However, UTF-8 is not a valid value for this flag. Is this something that can be reverted or is there some case where it actually works? As a temporary workaround I was able to redefine LC_CTYPE in each of the bash scripts in the workflow, but hopefully that should not be necessary going forward. export LC_CTYPE="$(defaults read -g AppleLocale).UTF-8" Download a simple workflow that tests this bug. Type lcctype in alfred then action the result – it should show your current locale in large type but will instead fail with an exception. Edited April 14, 2015 by ipaterson Caleb Grove 1 Link to comment Share on other sites More sharing options...
Andrew Posted April 15, 2015 Share Posted April 15, 2015 Hmm this is off the back of this post: http://www.alfredforum.com/topic/5582-sensible-defaults-or-a-clear-explanation-of-escaping-options/?p=34485 I'll look into this today and get a fix out! Link to comment Share on other sites More sharing options...
Andrew Posted April 15, 2015 Share Posted April 15, 2015 I've just popped out 2.7.1 which reverts the LC_CTYPE change - would you mind updating and trying this out? I'm keen to close this issue! Cheers, Andrew Link to comment Share on other sites More sharing options...
ipaterson Posted April 15, 2015 Author Share Posted April 15, 2015 Well done, in 2.7.1 the workflow is working again. I will follow up on the original discussion with some further thoughts. Link to comment Share on other sites More sharing options...
Andrew Posted April 15, 2015 Share Posted April 15, 2015 Well done, in 2.7.1 the workflow is working again. I will follow up on the original discussion with some further thoughts. Perfect, thanks for the feedback Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now