Jump to content

Alfred 5 open URL: is URL escaping a breaking change?


Recommended Posts

Hello!

 

I've recently migrated to Alfred 5 and noticed that some of my workflows stopped generating correct URLs. It seems that the issue happens because all of my Open URL actions have "encode {query} placeholder" and "encode {var:} placeholders" checkboxes enabled.

 

Is a newly created feature? I guess it's a breaking one then?

 

I guess, I can do automatic replacement in plist files for the following keys:

 

<key>skipqueryencode</key>
<false/>
<key>skipvarencode</key>
<false/>

 

What are your thoughts on that? Thanks for any help and advice!

Link to comment

@everyonesdesign Under normal use, these should be left as encoded and they should work the same between v4 and v5.

 

Could you please share an example of a URL from one of your Open URLs which is causing incorrect encoding so I can take a look what's happening in your case? Also, what you're typing as the query argument when using.

 

Cheers,

Andrew

Link to comment

Unfortunately I cannot export the workflow, since it was made for navigating internal URLs of my employing organisation; however I can share a simple setup reproducing the problem.

 

So it happens because I'm generating the path for the page, including slash symbols, but in some cases it feels very natural to do so (check out the simple example with the Github repo URLs generation).

 

BTW, I tried running an automatic replacement of `skipvarencode` and `skipqueryencode` values to `true`, and it fixed my problem.

 

Not sure how to attach Alfred workflow file here, it seems to only allow images, so I'm sharing via Dropbox: https://www.dropbox.com/s/68nzex09ats7npb/[Example workflow] Popular Github projects.alfredworkflow?dl=0

Link to comment

@everyonesdesign Ah yes, in this specific case, unticking the encoding option is the correct thing to do.

 

The Open URL object is now significantly more flexible, but you need to tell it what your intention is as {query} and {var} can now constitute any part of the URL. I'm going to continue to refine this over time and see if this can be some what more autonomous.

 

Here is my discussion on this issue:

 

Cheers,

Andrew

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...