Paul Harrison Posted September 28, 2020 Share Posted September 28, 2020 I'm a heavy user of iCloud. Why can't Alfred search see any of the files or folders that are there? I have added ~/Library/CloudStorage/iCloudDrive to the search scope. I'm using Alfred 4.1.1 with Mac OS Cataline 10.15.7. Link to comment Share on other sites More sharing options...
Andrew Posted September 29, 2020 Share Posted September 29, 2020 @Paul Harrison Apple have moved it around a few times during betas, but iCloud Drive is currently in ~/Library/Mobile Documents/ - Is this in your default search scope? (it should be by default). If it is, is Spotlight finding files in iCloud Drive? Try dragging one of the files which can't be found into Alfred's File Search Troubleshooting, found in Alfred's Help preferences. Cheers, Andrew Link to comment Share on other sites More sharing options...
Paul Harrison Posted September 29, 2020 Author Share Posted September 29, 2020 Hi Andrew Thanks for your reply. I forgot to say that ~/Library/Mobile Documents/ is also added to the search scope. All diagnostics on the file search troubleshooting are fine. The file details are: File: 'Toffee.pdf' Path: '/Users/paul/Library/Mobile Documents/com~apple~CloudDocs/Documents' This path is included in ~/Library/Mobile Documents/ so it should appear in search results? Link to comment Share on other sites More sharing options...
Vero Posted September 29, 2020 Share Posted September 29, 2020 @Paul Harrison Are the files appearing in Spotlight's results? If you open System Preferences > Apple ID > iCloud, is Optimised Storage on or off? In order for iCloud to store the actual files on your Mac (rather than storing them in the cloud and requesting them only when needed), Optimised Storage should be off. Cheers, Vero Link to comment Share on other sites More sharing options...
Andrew Posted September 29, 2020 Share Posted September 29, 2020 2 hours ago, Paul Harrison said: All diagnostics on the file search troubleshooting are fine. @Paul Harrison further to @Vero's questions, can I see the output of the File Troubleshooting? Link to comment Share on other sites More sharing options...
Paul Harrison Posted September 29, 2020 Author Share Posted September 29, 2020 (edited) OK, this is now working, I simply had to switch on "Search all file types". This is presented as a strongly discouraged option, but to me it's essential that search look at all file types. So I own up to this one. It's been worthwhile as I've learned more about how Alfred's search works. Edited September 29, 2020 by Paul Harrison Link to comment Share on other sites More sharing options...
Vero Posted September 29, 2020 Share Posted September 29, 2020 @Paul Harrison There are significantly more efficient ways to search for files than turning on that file type. Could you provide the File Troubleshooting output so that we can help you further? Link to comment Share on other sites More sharing options...
Paul Harrison Posted September 29, 2020 Author Share Posted September 29, 2020 OK - here is the diagnostic for a file which is in 'iCloud Drive', but doesn't show up in search unless "search all file types" is on. Starting Diagnostics... File: 'testmp4.mp4' Path: '/Users/paul/Library/Mobile Documents/com~apple~CloudDocs' ----------------------------------------------------------- Check file cache database... ✅ File cache integrity is ok ----------------------------------------------------------- Check if file is readable... ✅ Alfred has permissions to read this file. ----------------------------------------------------------- Check file is in search scope... ✅ File exists within Alfred's default search scope ----------------------------------------------------------- Check if volume '/' is indexed by macOS... ✅ Indexing is enabled on this drive ----------------------------------------------------------- Check direct file metadata... ✅ Direct metadata available Display Name: testmp4.mp4 Other Names: Content Type: public.mpeg-4 Last Used: 2020-09-20 20:30:09 +0000 ----------------------------------------------------------- Check mdls file metadata... ✅ Metadata contains required items _kMDItemDisplayNameWithExtensions = "testmp4.mp4" kMDItemAudioBitRate = 47 kMDItemAudioChannelCount = 1 kMDItemCodecs = ( "H.264", "MPEG-4 HE AAC" ) kMDItemContentCreationDate = 2020-09-20 20:29:44 +0000 kMDItemContentCreationDate_Ranking = 2020-09-20 00:00:00 +0000 kMDItemContentModificationDate = 2020-09-20 20:30:06 +0000 kMDItemContentModificationDate_Ranking = 2020-09-20 00:00:00 +0000 kMDItemContentType = "public.mpeg-4" kMDItemContentTypeTree = ( "public.mpeg-4", "public.movie", "public.audiovisual-content", "public.data", "public.item", "public.content" ) kMDItemDateAdded = 2020-09-21 09:17:56 +0000 kMDItemDateAdded_Ranking = 2020-09-21 00:00:00 +0000 kMDItemDisplayName = "testmp4.mp4" kMDItemDocumentIdentifier = 39300 kMDItemDurationSeconds = 48.179 kMDItemFSContentChangeDate = 2020-09-20 20:30:06 +0000 kMDItemFSCreationDate = 2020-09-20 20:29:44 +0000 kMDItemFSCreatorCode = "" kMDItemFSFinderFlags = 0 kMDItemFSHasCustomIcon = (null) kMDItemFSInvisible = 0 kMDItemFSIsExtensionHidden = 0 kMDItemFSIsStationery = (null) kMDItemFSLabel = 0 kMDItemFSName = "testmp4.mp4" kMDItemFSNodeCount = (null) kMDItemFSOwnerGroupID = 20 kMDItemFSOwnerUserID = 501 kMDItemFSSize = 889304 kMDItemFSTypeCode = "" kMDItemInterestingDate_Ranking = 2020-09-20 00:00:00 +0000 kMDItemKind = "MPEG-4 movie" kMDItemLastUsedDate = 2020-09-20 20:30:09 +0000 kMDItemLastUsedDate_Ranking = 2020-09-20 00:00:00 +0000 kMDItemLogicalSize = 889304 kMDItemMediaTypes = ( Video, Sound ) kMDItemPhysicalSize = 892928 kMDItemPixelHeight = 400 kMDItemPixelWidth = 224 kMDItemProfileName = "HD (1-1-1)" kMDItemStreamable = 0 kMDItemTotalBitRate = 143 kMDItemUseCount = 3 kMDItemUsedDates = ( "2020-09-19 23:00:00 +0000" ) kMDItemVideoBitRate = 95 ----------------------------------------------------------- ✅ Troubleshooting passed Link to comment Share on other sites More sharing options...
Andrew Posted September 29, 2020 Share Posted September 29, 2020 @Paul Harrison try using Alfred's 'open' keyword (which is the File Search mode), or by prefixing your search with the spacebar, e.g. show Alfred and type: [spacebar]testmp4 Link to comment Share on other sites More sharing options...
Paul Harrison Posted September 29, 2020 Author Share Posted September 29, 2020 OK thanks very much. That works. This has been a lot of learning. I understand that Alfred is all about power and flexibility, but all of this underlines to me that the search system isn't the most intuitive - and I still don't understand why I wouldn't want to "search all file types" by default. Link to comment Share on other sites More sharing options...
deanishe Posted September 29, 2020 Share Posted September 29, 2020 (edited) 6 hours ago, Paul Harrison said: I still don't understand why I wouldn't want to "search all file types" by default. Because it would be slow and you would have to sift through a large number of results to find the one you're interested in. And it wouldn't work particularly well because Alfred isn't optimised to be used that way. Alfred is designed around the idea of having multiple, tightly-focussed searches. You set up a custom search that only shows folders (with the keyword f, for example), and then you can go directly to the folder you’re interested in without having dozens of other types of files cluttering up the results. Or you set up a search that only looks in the directory where you keep your software licences or PDF manuals for your household devices, or your reference materials for a particular project. The point is most of the time, you don’t want to search everything and see what turns up. You already have a fairly good idea of what you’re looking for and where it is. So you set up individual searches for your most common search tasks and the rest of the time, you use Alfred's open command (or Spotlight). You can configure Alfred to search everything if you really want to. But you’d be throwing away most of its power and speed by doing so. Edited September 29, 2020 by deanishe Link to comment Share on other sites More sharing options...
Ravotten23 Posted November 3, 2021 Share Posted November 3, 2021 (edited) Hey all, I have the same problem as OP I've been messing around with my iCloud config since getting a new mac. Turned the option in iCloud drive to backup 'Desktop and Documents' option on and then back off again and since then Alfred hasn't been finding my iCloud docs... I turned off Optimised mac-storage due to reading an earlier comment, still no luck. Also rebuilt macOS metadata without luck either. This problem was happening on Big Sur and is still occurring on Monterey now. Here's a diagnostic file for a Word document that is in icloud but not appearing in Alfred search: Starting Diagnostics... File: 'On learning (psychotherapy).docx' Path: '/Users/samuelf/Library/Mobile Documents/com~apple~CloudDocs/Documents' ----------------------------------------------------------- Check file cache database... ✅ File cache integrity is ok ----------------------------------------------------------- Check if file is readable... ✅ Alfred has permissions to read this file. ----------------------------------------------------------- Check if volume '/' is indexed by macOS... ✅ Indexing is enabled on this drive ----------------------------------------------------------- Check direct file metadata... ⚠️ Direct metadata is missing, this file is likely not indexed by macOS Display Name: Other Names: Content Type: Last Used: ----------------------------------------------------------- Check mdls file metadata... ❌ macOS metadata missing essential items kMDItemFSContentChangeDate = (null) kMDItemFSCreationDate = (null) kMDItemFSCreatorCode = "" kMDItemFSFinderFlags = (null) kMDItemFSHasCustomIcon = (null) kMDItemFSInvisible = 0 kMDItemFSIsExtensionHidden = (null) kMDItemFSIsStationery = (null) kMDItemFSLabel = (null) kMDItemFSName = (null) kMDItemFSNodeCount = (null) kMDItemFSOwnerGroupID = (null) kMDItemFSOwnerUserID = (null) kMDItemFSSize = (null) kMDItemFSTypeCode = "" ----------------------------------------------------------- ❌ Troubleshooting failed Thanks in advance! Sam Edited November 3, 2021 by Ravotten23 Link to comment Share on other sites More sharing options...
Vero Posted November 3, 2021 Share Posted November 3, 2021 @Ravotten23 As you can see from the troubleshooter, the files in question are not indexed by macOS. The first steps to follow when results seem unexpected is to rebuild your Mac's metadata. It's usually because the data being provided by macOS is incorrect (even if it appears correct in the current Spotlight cache), and rebuilding ensures that all this information is refreshed by the OS. Even if you believe you've already reindexed, please follow the steps below specifically (as it involves deleting a cache first and ensuring Terminal has suitable permissions). First, please pop open System Preferences > Security & Privacy > Privacy > Full Disk Access and add Terminal Once you've done this, go to Alfred's Advanced preferences, choose "Rebuild macOS Metadata" Ensure that you check "Delete .Spotlight-V100 before reindex" Follow the steps in Terminal, and keep a close eye for any error messages relating to your index. Please let me know if there are any errors. Otherwise, if it proceeds smoothly, you may need to wait up to an hour for the reindex to complete. Once this is done, make your searches again and see if your results are more as expected. If your issue persists, please provide the following information: Your diagnostics file, by typing ?diagnostics into Alfred and emailing it to our info@ address, referencing this thread Output from File Troubleshooting reports for the files you cannot find using Alfred to see if anything's changed. Cheers, Vero Link to comment Share on other sites More sharing options...
Ravotten23 Posted November 6, 2021 Share Posted November 6, 2021 It worked! Thanks a lot 🙂 Link to comment Share on other sites More sharing options...
Ravotten23 Posted November 17, 2021 Share Posted November 17, 2021 Hey, The full reindexing gave me some functionality, but I'm not back to 100% like before on my previous Mac. It seems that Alfred: 1) Doesn't work for documents that are currently open anymore? As I have many documents open, it's incredibly useful to be able to search for those ones too, but now these just don't appear in the search anymore; at least my most recent documents. The older ones do still always appear in the search. 2) Some docs (I believe more recent ones) are not listed in Alfred search results but when I open them (through finder) and then search for them, there they are listed again; but then they re-disappear after some time!! I wonder if it's my iCloud storage structure or what, but it's quite annoying. I save everything on Documents (iCloud) and do not have "backup documents and desktop" active. It's since I messed around with turning this on that I've had these problems but it's also a new device so not sure what's the issue... Here's an example from a file after total re-indexing as described by @Veroabove. This file does not appear in Alfred search as seen below; however, if I open it with Microsoft Word and then search (while it's open) I get it in the search results... For a time, at least. Any help appreciated, Thanks! Starting Diagnostics... File: 'BGE.docx' Path: '/Users/samuelferrard/Library/Mobile Documents/com~apple~CloudDocs/Documents' ----------------------------------------------------------- Check file cache database... ✅ File cache integrity is ok ----------------------------------------------------------- Check if file is readable... ✅ Alfred has permissions to read this file. ----------------------------------------------------------- Check if volume '/' is indexed by macOS... ✅ Indexing is enabled on this drive ----------------------------------------------------------- Check direct file metadata... ⚠️ Direct metadata is missing, this file is likely not indexed by macOS Display Name: Other Names: Content Type: Last Used: ----------------------------------------------------------- Check mdls file metadata... ❌ macOS metadata missing essential items kMDItemFSContentChangeDate = (null) kMDItemFSCreationDate = (null) kMDItemFSCreatorCode = "" kMDItemFSFinderFlags = (null) kMDItemFSHasCustomIcon = (null) kMDItemFSInvisible = 0 kMDItemFSIsExtensionHidden = (null) kMDItemFSIsStationery = (null) kMDItemFSLabel = (null) kMDItemFSName = (null) kMDItemFSNodeCount = (null) kMDItemFSOwnerGroupID = (null) kMDItemFSOwnerUserID = (null) kMDItemFSSize = (null) kMDItemFSTypeCode = "" ----------------------------------------------------------- ❌ Troubleshooting failed Link to comment Share on other sites More sharing options...
jpage4500 Posted December 6, 2021 Share Posted December 6, 2021 this issue sounds a lot like the one I'm seeing too. In my case I'm using Google drive and not iCloud but maybe they have the same root issue. Link to comment Share on other sites More sharing options...
Stratocumulus Posted June 27, 2022 Share Posted June 27, 2022 Having the same issue with iCloud files. Been through all the posts above and done all rebuilding etc. Files still don't show up (but they do in Spotlight). Any ideas? Thanks. Link to comment Share on other sites More sharing options...
marine7382 Posted September 16, 2022 Share Posted September 16, 2022 Same issue here, but I think I found the problem! iCloud files are not located in your Home folder. So I went to Alfred Preferences -> Features -> Default Results -> Search Scope and then hit "+" to add my entire disk volume ("Macintosh HD") to the search scope. That seems to have fixed the problem of not locating files saved in iCloud. Link to comment Share on other sites More sharing options...
3point Posted November 8, 2022 Share Posted November 8, 2022 Alfred is not finding iCloud files that are stored on the cloud only. They are visible in spotlight and in the finder, but do not show in Alfred while browsing folders. Is this a limitation of Alfred? Link to comment Share on other sites More sharing options...
Vero Posted November 8, 2022 Share Posted November 8, 2022 @3point Could you take a look at the troubleshooting and drag some files in to see whether they have any metadata and whether it's complete? Please make sure you're using Alfred 5.0.5 first, as we've improved the File Troubleshooter output to be a little more detailed. https://www.alfredapp.com/help/troubleshooting/indexing/ Let us know how you get on Link to comment Share on other sites More sharing options...
3point Posted November 8, 2022 Share Posted November 8, 2022 Hello @Vero , Thank you for your reply. I am attaching a couple of screen shots and the troubleshooting output. I have enabled full disk access but diagnostics says Alfred does not have permissions... Thank you so much in advance! Files in actual folder. Some are downloaded locally, some are icloud only. Alfred Browsing results: Starting Diagnostics... File: 'Intro to Ecology Lecture Notes 2020 pcb.pages' Path: '/Users/stillerb/Documents/__shared New Trier/New Trier/00 BIOLOGY/00 Biology units /01 intro to biology' ----------------------------------------------------------- Check file cache database... ✅ File cache integrity is ok ----------------------------------------------------------- Check if file is readable... ❌ Alfred does not have permissions to read this file. Check if Full Disk Access is granted in the macOS Security & Privacy preferences. ----------------------------------------------------------- ❌ Troubleshooting failed Link to comment Share on other sites More sharing options...
Vero Posted November 8, 2022 Share Posted November 8, 2022 @3point Which version of macOS are you using? If you're on Ventura, did the issue start when you upgraded? And did you upgrade during the beta period or at general release? First, I'd try resetting permissions: https://www.alfredapp.com/help/getting-started/permissions/#regrant It's possible that macOS's permissions data is corrupted, which isn't unheard of on major OS upgrade. Resetting should resolve that. Let me know how you get on Link to comment Share on other sites More sharing options...
3point Posted November 8, 2022 Share Posted November 8, 2022 @Vero I am running MacOS 12.6 and resetting permissions did not work. My machine is managed and has a ton of security profiles installed. Perhaps that could cause the issue. Link to comment Share on other sites More sharing options...
3point Posted November 14, 2022 Share Posted November 14, 2022 @Vero I may have figured something out and maybe you can help me. It appears that Alfred can find files that are only on the iCloud drive cloud using quick file search, but it can't find the same file while browsing in Alfred. Browsing in Alfred can find downloaded files which appear to have regular names ( e.g. ~/Spinach Growth Lab.pages). The iCloud only files that Alfred cannot find are not downloaded to local disk and begin with a "." in their name and end with ".icloud" (e.g. ~/.Intro to Ecology Lecture Notes 2020 pcb.pages.icloud) That appears to be the main differences. Thanks for your help. Link to comment Share on other sites More sharing options...
Vero Posted November 15, 2022 Share Posted November 15, 2022 @3point Ah that's interesting - Anything that begins with a . should be a hidden or temporary file, which Spotlight doesn't index. If you disable Optimised Storage for iCloud (which ensures that your files are stored locally and "real" rather than just virtual references to online files), are they found? On 11/8/2022 at 3:37 PM, 3point said: My machine is managed and has a ton of security profiles installed. Perhaps that could cause the issue. It does appear that there are permissions issues. Are you able to provide Alfred with Full Disk Access in the system prefs? Or is this restricted? 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