Hazel does not recognize content

Get help. Get answers. Let others lend you a hand.

Moderator: Mr_Noodle

Hazel does not recognize content Sat Feb 20, 2016 5:08 pm • by Momolino
I created some basic rules to find and rename specific pdf files. The rules are: kind is pdf, content contains "Word1", content contains "Word2". The rule applies to a specific folder, the files were created by Scansnap, there are no subfolders. Hazel only recognizes some of the files which apply to the rule. If I open the files not recognized by Hazel in Preview I can find the Word1 and Word2 with the search-tool and I can also find the files with Finder (and Word1 and Word2). They are pdf-files. Where is the problem?
Momolino
 
Posts: 8
Joined: Sat Feb 20, 2016 4:57 pm

Re: Hazel does not recognize content Mon Feb 22, 2016 12:14 pm • by Mr_Noodle
If you try "Contents contain match" instead, does that change anything?
Mr_Noodle
Site Admin
 
Posts: 11255
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Hazel does not recognize content Mon Mar 07, 2016 2:31 pm • by MRE
I have exactly the same problem with scanned documents (Fujitsu ScanSnap) and Hazel.
There is no difference between "content contain" "content - contain matching".

I spent days now, but it doesn´t work well.
Could it be an issue with the kind of text recognition of SnapScan software?
But why Finder preview find the words then?

Do you have any ideas?
Do you have a recommendation for a reliable text recognition software, which definitely works fines with Hazel and which I can test?

Sincerely,
MRE
MRE
 
Posts: 1
Joined: Mon Mar 07, 2016 2:19 pm

Re: Hazel does not recognize content Tue Mar 08, 2016 10:53 am • by Mr_Noodle
I suggest you email support with the specific rule/file in question.
Mr_Noodle
Site Admin
 
Posts: 11255
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Hazel does not recognize content Sat Jun 18, 2016 5:40 pm • by Brax
I have the exact same problem. One day Hazel is working fine. The next all rules using the "contain" condition will no longer work. I suspect this has happened to me before as I have banged my head against the wall in the past with my rules failing to work only to have them start working again.

There's either a bug in Hazel or perhaps some suspension in spotlight indexing (assuming you are building on top of Spotlight).. Either way, something is going on here..

I even went as far as finding a PDF that I downloaded and used Hazel to simply open it if it matched a word inside just to rule out PDF files scanned with my ScanSnap as the source of the issue.
Brax
 
Posts: 2
Joined: Sat Jun 18, 2016 5:34 pm

Re: Hazel does not recognize content Mon Jun 20, 2016 11:19 am • by Mr_Noodle
Most likely Spotlight. If you don't mind the performance hit, you can try using "contain match" instead.
Mr_Noodle
Site Admin
 
Posts: 11255
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Hazel does not recognize content Sat Jun 25, 2016 7:51 pm • by paulhubert
I had this problem with a string I was able to SELECT when accessing the PDF (scanned via Fujitsu ScanSnap ix-500). The first string I selected identified the COMPANY and I thought was a better match. I selected another string and Hazel performed the action needed.

In one case, I tried matching on the string "Account number nnnnnnnnnnn" which would be good for credit card and bank statements, but THAT failed. I am scanning to a "Scan default" folder, and having Hazel rename and move the files from billings and statements. Overall it is working well.

Where can I go to find how Hazel works with Applescript, since nested IF-THEN-ELSE could be useful to create a single Hazel entity (IF it would accomplish that) to handle different forms of files, rather than having a long list of Hazel rules (I'm a former programmer, but not C, Cobol (MINIMAL) or Bash, et al (RCA/UNIVAC (~IBM 360/370) Assembly*, Tandem TACL, Stratus command language*, UNIVAC VS/9 EDT* among others -- *VERY good & extensive.).

It would be GREAT if Hazel could someday have the above - multiple nested conditions with multiple end results in a single routine.
paulhubert
 
Posts: 12
Joined: Tue Jun 14, 2016 2:21 pm

Re: Hazel does not recognize content Sun Jun 26, 2016 11:54 pm • by LarryJay
Brax wrote:I have the exact same problem. One day Hazel is working fine. The next all rules using the "contain" condition will no longer work. I suspect this has happened to me before as I have banged my head against the wall in the past with my rules failing to work only to have them start working again.

There's either a bug in Hazel or perhaps some suspension in spotlight indexing (assuming you are building on top of Spotlight).. Either way, something is going on here..

I even went as far as finding a PDF that I downloaded and used Hazel to simply open it if it matched a word inside just to rule out PDF files scanned with my ScanSnap as the source of the issue.


I've had the same problems. You can tell it to run rules in a file and it will just sit there. Then there is the time when the rules will work no more and will work later or on the nest restart.

There's a problem....
LarryJay, still a novice Hazel'er.
LarryJay
 
Posts: 6
Joined: Sat Jun 23, 2012 5:17 pm

Re: Hazel does not recognize content Mon Jun 27, 2016 11:39 am • by Mr_Noodle
paulhubert: I think you problem is unrelated and should be its own topic. Also, search the support site on nested conditions.

LarryJay: As noted already, please check your Spotlight configuration. "contain" is dependent on it. If Spotlight isn't indexing the files properly, the it won't work in Hazel either. The alternative to fixing that is to use "contain match".
Mr_Noodle
Site Admin
 
Posts: 11255
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Hazel does not recognize content Sun Jul 10, 2016 1:15 pm • by bpd
Mr_Noodle wrote:LarryJay: As noted already, please check your Spotlight configuration. "contain" is dependent on it. If Spotlight isn't indexing the files properly, the it won't work in Hazel either. The alternative to fixing that is to use "contain match".


I have the same problem. It's not a matter of "contains" vs. "contains match". It's a matter of "Contents" searching not working. I can confirm that Spotlight has the data I'm looking for. Hazel just stopped being able to see it. I've tried creating new rules just doing simple contents matches (e.g. searching for my name in a PDF vs. doing a structured date match). Hazel won't find anything in the PDFs, whereas Spotlight brings them right up.

I've turned on Debug mode, but even with that on, Hazel doesn't appear to log anything while Previewing. When I force rules to run on a folder, logging simply says the files didn't match any rules.

When I'm Previewing in the rule editor, if I select the parent folder and click on the X indicating that Contents didn't match anything, it shows "Contents" as an empty field. If I select an individual file, the X shows the contents of the file—including the string that should match—yet nothing matches.

Clearly there's something wrong in Hazel. Let me know if I can provide any further information to help diagnose what it is.
bpd
 
Posts: 1
Joined: Sun Jul 10, 2016 12:59 pm

Re: Hazel does not recognize content Tue Jul 12, 2016 1:26 pm • by Mr_Noodle
In the preview, you should be using the parent folder. Unless your rule is supposed to match folders, that doesn't make sense. You do need to preview the individual file to see the contents.

You'll need to provide specifics for me to be able to delve into this more. Things like the exact text you are searching for. Spotlight results from searching for that text. The text as Hazel sees it in the preview. etc.
Mr_Noodle
Site Admin
 
Posts: 11255
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Hazel does not recognize content Wed Jul 13, 2016 2:31 am • by peterflorijn
I have this problem to. Suddenly Hazel stopped recognizing content in my PDF.
This was working perfectly before.

Spotlight search works OK

Text I'm searching for is and account nr of 5 digits and a supplier name.
peterflorijn
 
Posts: 3
Joined: Mon Nov 19, 2012 5:31 am

Re: Hazel does not recognize content Wed Jul 13, 2016 11:46 am • by Mr_Noodle
Can you post an image or enclose the search text in quotes as I'm having a problem parsing your sentence? Also, have you tried using "contains match" instead and are the results different?
Mr_Noodle
Site Admin
 
Posts: 11255
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Hazel does not recognize content Wed Jul 20, 2016 4:31 am • by peterflorijn
When I change the rule to contain match it works OK.

All my rules that use contain are broken.
peterflorijn
 
Posts: 3
Joined: Mon Nov 19, 2012 5:31 am

Re: Hazel does not recognize content Wed Jul 20, 2016 10:47 am • by Mr_Noodle
Are you sure that Spotlight is working properly for those files then?
Mr_Noodle
Site Admin
 
Posts: 11255
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Next

Return to Support