NC overwrite behavior potentially affecting other applications [CLOSED]

Questions, glitches, bugs and crashes
Locked
JayB
Posts: 192
Joined: Sun Jan 08, 2017 4:38 pm

NC overwrite behavior potentially affecting other applications [CLOSED]

Post by JayB » Sat Feb 10, 2018 11:14 am

This has to do with the way Nimble Commander replaces (overwrites) applications. (Currently only from DMGs, because unzipped applications can't (yet) be used to replace (overwrite) .app bundles in /Applications.)

This happened with the new VLC v3.0.0, which I just copied from the DMG into /Applications and instructed NC to overwrite (just "overwrite", not "overwrite older") the old /Applications/VLC.app. Then at launch, VLC repeatedly crashed. It now works, but only after I removed the VLC.app altogether, and copied the new VLC into /Applications completely fresh. This is the resulting comment from the videolan bug tracker:
The crash report says that I cannot find the icon file (VLC.icns), there
is nothing more in it.

The problem is that Nimble Commander does not behave correctly while
copying the new VLC (I tried it out): It tries to "merge" the old
directory (existing VLC.app/) with the new directory (new VLC.app/). This
results in a mix of old and new files all together, which can cause
all sorts of issues (which you likely did not even notice yet).

In this particular issue, the old VLC.app has the file "vlc.icns" (lower
case), and the new bundle has the same file upper case. As you are likely
running on a case-insensitive file system, your tool just keeps the old
file, which causes the crash.

Solution: Do NOT use such "Nimble Commander" for installing any
applications. Any normal installer completely removes the old app, before
copying the new one. You should probably file a bug report with them, that
they also implement that correctly.
So I assume that when overwriting a directory that is in fact a com.apple.bundle or com.apple.package etc. (i.e. an app, a preference pane, a kext, a framework etc.), NC should just do a full-on replace, case-insensitive or -sensitive doesn't matter, because it would not be keeping anything unique to the destination anyway, i.e. it would basically be just a removal of the bundle/package, then copy the new one in its place. Sure, users can do this manually, but many (if not most) install applications by drag & drop to /Applications, or by simply staying in the DMG volume and dragging/dropping the .app to the /Applications symbolic link.

User avatar
mike
Posts: 1060
Joined: Thu Jul 16, 2015 5:35 am
Location: Exeter, UK

Re: NC overwrite behavior potentially affecting other applications

Post by mike » Mon Feb 12, 2018 12:34 pm

Well, yes, NC does a non-destructive directory copy, and that's a right thing to do.
Speaking of adding some "intelligence" here - I'm much against magical behavior based on type of a content, this approach only increases uncertainty.
You can even imagine the opposite situation - an app with a bunch of custom-added plugins, in this case a removal of an entire app before copying is the last thing you would expect.

JayB
Posts: 192
Joined: Sun Jan 08, 2017 4:38 pm

Re: NC overwrite behavior potentially affecting other applications

Post by JayB » Mon Feb 12, 2018 2:33 pm

OK, thank you, then it's back to the old behavior: first delete the old version of an app from /Applications, then move the new one there.

Locked