sbarex / MediaInfo

MacOS Finder Extension to show information about media files (images, video and audio), PDF and Office files on the contextual menu.
322 stars 6 forks source link

MediaInfo data disappearing from the contextual menu #11

Closed Joolyan closed 2 years ago

Joolyan commented 2 years ago

With the success of 'Syntax Highlight.app' replacing QLColorCode.qlgenerator and QLStephen.qlgenerator, I thought I'd try MediaInfo.app to replace qlImageSize.qlgenerator

Given Apple's new restrictions, MediaInfo.app works really well and I love the customisation options.

However, I do have an issue where it 'just works' then at some point the MediaInfo data disappears from the contextual menu, even when selecting the same files in the same location. Relaunch Finder and all is good, until it disappears again.

My question... Is there anything which might help identify the cause? As I don't know when it disappears, I'm not sure what I'm looking for.

System: Intel MacBook Pro with Big Sur 11.6.1 and MediaInfo 1.5.4

sbarex commented 2 years ago

When the extension works, the Activity Monitor shows two processes: MediaInfo Finder Extension and MediaInfo Helper XPC.

Schermata 2021-12-10 alle 23 42 38

When the extension stop working the processes still exists?

The app only stops working when you try to open some kind of file in particular?

Also you can check with the Console.app the log of the mediainfo process.

Joolyan commented 2 years ago

Thanks. I now have something to look for when MediaInfo stops working.

I currently have 7 copies of MediaInfo Helper XPC and MediaInfo Finder Extension open in Activity Monitor, which I assume is because I have 6 tabs open in Finder.

The app only stops working when you try to open some kind of file in particular?

That will be difficult to answer, as I don't know when the issue occurs - until I next check the contextual menu. I'll update the issue when I have more information.

sbarex commented 2 years ago

MasOS can create maby instances of the Finder Extension. From the official docs:

The system may also launch additional copies of your extension whenever an Open or Save dialog is displayed. This means that the user may have multiple copies of your extension running at once, and some may be very short lived.

If the problem occurs only with a specific file it is possible that it is due to a bug on extracting / rendering the properties of the file

Joolyan commented 2 years ago

If the problem occurs only with a specific file

The problem may be caused by a specific file, but if it is, it kills all MediaInfo data for all images, videos and audio files.

I'll update the next time it happens.

Joolyan commented 2 years ago

All was working this morning, but now the Finder contex menu is missing MediaInfo data.

When the extension stop working the processes still exists? Yes. (MediaInfo Finder Extension & MediaInfo Helper XPC) The app only stops working when you try to open some kind of file in particular? MediaInfo is missing for all file types.

Relauching Finder restores the missing MediaInfo data, but I've just realised that MediaInfo isn't the only Finder extension which stops working, as the contextual menu is missing Dropbox and BetterZip options from the contextual menu, all restored after relauching Finder.

The problem may not be caused by MediaInfo. I'll try disabling each of the Finder extensions to try to identify the problem extension.

Joolyan commented 2 years ago

Sorry to have to report that it looks like MediaInfo.app is causing the issue.

I disabled the MediaInfo Finder extension then restarted and all Finder extensions have been working for the last 48 hours. I then re-enabled the MediaInfo Finder extension and all appeared to be working - but not for long...

Checking an svg file I noticed the contextual menu was now missing MediaInfo, Dropbox and BetterZip, for all folders setup as 'Monitored folders' in MediaInfo. All other folders still include Dropbox and BetterZip contextual links.

In summary, it appears as if MediaInfo is somehow hiding/blocking the Dropbox and BetterZip extensions, displaying contextual links in the MediaInfo monitored folders. Disabling the MediaInfo Finder extension and closing all MediaInfo processes using the Activity Monitor.app restores the Dropbox and BetterZip contextual menus, without relaunching Finder

Screenshot - 4085863368097255 AFTER Screenshot - 4085863368097255 BEFORE .

sbarex commented 2 years ago

the problem is only with svg files?

Joolyan commented 2 years ago

The problem doesn't just effect svg files. Once the problem occurs MediaInfo, BetterZip and Dropbox are missing from all media types in the MediaInfo monitored folders. However the problem may be triggered by svg files, but if it is, it's certainly not all svg files.

Joolyan commented 2 years ago

Hopefully this issue can be closed, as the problem appears to have been caused by a Finder extension installed with pCloud.app (a Dropbox competitor from pCloud.com). Uninstalling pCloud.app appears to have resolved the issue. It's possible there was a conflict between MediaInfo and the version of pCloud I was testing, but happy to uninstall pCloud to use MediaInfo without issues.