Mac Dock Bug. Even when App is in dock as shortcut, app opens new instance in Dock.
Open, NormalPublic

Description

Hi,

It's common in mac to drag the app into the dock to create a shortcut for it. In macOS Sierra 10.12 this functionality doesn't work as it should.

After dragging Blender into the dock, when clicking on the Blender Icon in the dock it opens the app in a new instance on the dock.

As you can see app is already in the dock and then when clicked on it opens a new icon over to the right.

Just a bit odd..

Thanks

Details

Type
Bug

I have a similar issue with dock and blender. After reboot or login, blender's dock icon changes into question mark and stops working. Maybe it is related to this issue. If not, I will submit new bug report.

My problem seems related to Gatekeeper Path Randomization (GPR). After googling GPR, sierra, dock, etc. I have found a solution here: https://forums.vandyke.com/showthread.php?t=12513

After using this command in Terminal:

xattr -dr com.apple.quarantine /Applications/blender/

blender icon stays in dock after restarting my laptop.
*change blender folder to the name of your folder, for example blender-2.78a-OSX_10.6-x86_64

@Timothy Jack (timothyj) maybe this would solve your problem too?

The attribute com.apple.quarantine cannot be set inside the zip. I suspect downloading the zip from blender.org does set this and extracting the zip sets it on all containing files.

We probably need to switch to a proper dmg based install to avoid this.

@Chris Slazinski (mallow) and @Martijn Berger (juicyfruit) Thank you both for looking into it.

@Chris Slazinski (mallow) I did have the question mark problem too, however I think after updating to latest Sierra it might have fixed it. (I cannot confirm though)
Thanks too re solution, I'd prefer to avoid a Terminal solution if possible :) Unfortunately the original dock problem I encountered is still there in latest Sierra.

@Martijn Berger (juicyfruit) Thank you, I hope we can keep the zip if possible :) Nice and simple.

@Chris Slazinski (mallow) I did have the question mark problem too, however I think after updating to latest Sierra it might have fixed it. (I cannot confirm though)

I'm on Mac OS 10.12.2; the problem still occurs here (Blender 2.78a).
I just noticed it after not having used Blender for a while.

filip mond (vklidu) added a comment.EditedFeb 23 2017, 12:24 PM

The same issue for me on OS X 10.12 (Sierra).
When I double click blender.app icon, then in this directory

/private/var/folders/jr/tfyh0hcn2kz477q0hpd108hm0000gn/T/AppTranslocation/

is generated like mount volume with subfolder "d" and "Blender.app" in it.
That is why second icon of running Blender in the OS X Dock.


Quiting blender ejects the volume.
It takes sometimes quite a long time.
Probably that is why OS writes "Can't be open because disk it is on has been ejected." when I close blender and try open quickly new one.


Only after this "volume" disappears from folder I can open another file.

Is arising some solution for this issue?
Thank you for help.

I came across to this when I saw an add-ons path displayed in user preferences.

Umm, I just moved the Blender icon out of the blender folder. No more second icon.

Same for me :) Thats the most wired step to fix I can confirm here :)
In czech we use to say "get out - get in" in meaning restart computer if you have a problem.
But this is literately that case :)

Even app is moved back into blender folder and I log out/in user it keeps one icon as supposed to.

Thank You!

I can confirm this works. Many thanks for such a simple fix.
For some reason it doesn't like the folder it is in from blender.org download zip.

I can create a new folder say 'Blender 2.78c' and put Blender in that, and then drag Blender app from the newly created folder to the dock and then open it - and it works in the one instance =) Perhaps a Mac os update has helped things too.

Tim

I too can confirm that placing Blender.app directly in /Applications solved the issue with a duplicate icon appearing in the dock. One solution besides creating a .dmg installer could be to have Blender.app placed alongside (instead of within) the folder that contains the licenses and extras (such as Blender Player). That way when users drag it to /Applications it's exactly where it needs to be from the start. Just an idea.

Pretty good fix here for it.

https://www.crowdrender.com.au/forum-1/getting-started/macos-gatekeeper-breaks-crowdrender

Seems for some reason Blender is getting wrongly quarantined even when using Right Click/Open.

@Chris Slazinski (mallow) indeed it is, big apologies I had not seen your comment when I came across this problem before.

@Andrei Nadin (AnadinX) No problem. I am glad it worked for you too :)

@Martijn Berger (juicyfruit) Thank you, I hope we can keep the zip if possible :) Nice and simple.

How is a .zip file simpler than a .dmg file?

I do think it would be good to address this, every nightly build or update or 2.8 version I have to remove blender from quarantine, its not really a desired behaviour.

@Martijn Berger (juicyfruit) Thank you, I hope we can keep the zip if possible :) Nice and simple.

How is a .zip file simpler than a .dmg file?

Agree with you. .zip is in no way better, simpler or easier than a .DMG. Actually, packing it as a signed DMG should avoid this issue. I'm new to Blender (not to Mac), and this gives a bad impression in beginners using Macs :(.