deanishe Posted March 2, 2014 Posted March 2, 2014 When using the Open URL action with the URL set only to {query}, Alfred fails silently if the passed arg contains non-ASCII characters.The following XML, which Alfred accepts and correctly displays in its results list, does nothing when the arg is sent to the Open URL action.The first item is as returned by Python's xml.etree.ElementTree library, the second I edited back to pure text form to see if that worked (it didn't).In both cases, Open URL performs perfectly provided {query} is only part of the URL, but fails if {query} is the entire URL. <?xml version="1.0" encoding="utf-8"?> <items> <item valid="yes"> <title>Göbekli Tepe - Wikipedia, the free encyclopedia</title> <subtitle>http://en.wikipedia.org/wiki/Göbekli_Tepe</subtitle> <arg>http://en.wikipedia.org/wiki/Göbekli_Tepe</arg> <icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/BookmarkIcon.icns</icon> </item> <item valid="yes"> <title>Göbekli Tepe - Wikipedia, the free encyclopedia</title> <subtitle>http://en.wikipedia.org/wiki/Göbekli_Tepe</subtitle> <arg>http://en.wikipedia.org/wiki/Göbekli_Tepe</arg> <icon>/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/BookmarkIcon.icns</icon> </item> </items>
Tyler Eich Posted March 3, 2014 Posted March 3, 2014 This feels like a bug. If you use a Run Script action/output (language: /bin/bash; escape: double quotes, backslashes) with the following code: open "{query}" …everything works perfectly, regardless of encoding.
deanishe Posted March 3, 2014 Author Posted March 3, 2014 I'm 99.9% certain it's a bug. The encoding is 100% correct: Alfred accepts the XML (indeed it would work with item 1 even if it were ASCII-encoded). That Open URL works fine if {query} is part of the URL, but fails if it's the entire URL squarely points the finger in Alfred's direction, IMO. It looks like Alfred follows a different code path if {query} is the entire URL (the UI options then become greyed out). Thar be bugs (well a bug), methinks.
deanishe Posted March 3, 2014 Author Posted March 3, 2014 (edited) Why has this been moved from the Bugs forum to the Workflow Help forum? It's a bug report, not a request for help! I suspect Andrew might think I don't know my text encoding from my elbow… Edited March 3, 2014 by deanishe
Tyler Eich Posted March 3, 2014 Posted March 3, 2014 Why has this been moved from the Bugs forum to the Workflow Help forum? It's a bug report, not a request for help! I suspect Andrew might think I don't know my text encoding from my elbow… For what it's worth, this was in "Workflow Help & Questions" when I replied to it. On top of that, I seriously doubt Andrew would move a post without replying to inform the original post's author.
deanishe Posted March 3, 2014 Author Posted March 3, 2014 (edited) Hmm, I'm pretty sure I posted it in the Bug Report forum, but as you say, I don't think Andrew would move it without saying anything, either, and it certainly wouldn't be the first time I done messed up… I guess I'll toddle off and post it in the Bug Report forum: it's doing no good in here. Edited March 3, 2014 by deanishe
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