Jump to content

"Search for '(null)' in Spotlight" subtext when activating List Filter via Hotkey


Recommended Posts

I activate a List Filter in a Workflow with a Hotkey combo:

 

image.png.d20bc295030f60052916775db48b1767.png

 

and when I press option, "Search for '(null)' in Spotlight" is shown as the subtext of the action:

 

1836017388_CleanShot2020-12-05at19_41.58@2x.thumb.png.9b6ad85213c9cdfe74301dd04f47c893.png

 

Hitting enter opens a Finder window, but of course it can't search for "null".

 

It seems like this behavior should be prevented?

Link to post
Share on other sites

@chris very interesting discovery, and I'm astounded that this hasn't been spotted sooner (as the logic behind this hasn't been touched in a long time).

 

While default mod actions should work here (and there are cases where an empty string is valid as the fallback arg), it definitely shouldn't show null. I've had a bit of a reorganise of the internal logic for this in the next build so you don't see null anymore.

 

Cheers,

Andrew

Link to post
Share on other sites
1 hour ago, Chris Messina said:

It's better...! Now it reads "Search for '' in Spotlight".

 

Well, technically Andrew did say "improved", not "fixed" ;)

 

I noticed a related blemish: If I run a List Filter with keyword (note trailing space), holding ⌥ shows Search for 'keyword ' with default fallback (with trailing space), but ^ shows Search for 'keyword' in Spotlight (without trailing space).

Link to post
Share on other sites
5 hours ago, Chris Messina said:

Also, it is not normal that when I key down to an option from the List Filter and hit the "shift" key, an empty Quicklook preview appears?

 

This depends upon what's in the arg field of the list filter... for the blank Quicklook, what arg do you have set?

Link to post
Share on other sites
4 hours ago, deanishe said:

I noticed a related blemish: If I run a List Filter with keyword (note trailing space), holding ⌥ shows Search for 'keyword ' with default fallback (with trailing space), but ^ shows Search for 'keyword' in Spotlight (without trailing space).

 

There is actually some underlying logic which is causing this to be the case. The default fallback gets the full typed query, the spotlight fallback gets the typed argument for the current context. You'll notice if you keep typing, the Spotlight one will change to showing the argument instead.

Link to post
Share on other sites

@deanishe a simplification of the logic is if you want to search e.g. Google, it's likely the entire input you want to search for. If you want to search in Finder, it prevents e.g. the "open" keyword from being included. It's difficult to second guess what would be the absolute right thing to do, but this logic has stood for many years.

Link to post
Share on other sites
1 hour ago, Andrew said:

Out of interest, what happens if you put a simple but complete URL just in the arg field of the list filter?

 

Ok. I think I've figured it out. The issue is that the link in question requires authentication and redirects to a sign in page. It appears that Quicklook doesn't handle this well, and so renders a blank page.

 

When I use shift to preview a link from another List Filter, it works as expected! 

 

I consider this resolved!

Link to post
Share on other sites

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