Page MenuHome

Version 2.77 package for OS X contains non-modifiable __pycache__ directories
Closed, ResolvedPublic

Description

System Information
OS X 10.11

Blender Version
Broken: 2.77
Worked: 2.76

Short description of error
The latest version 2.77 seems to include pycache directories for all Python libraries and all of them have dr-xr-xr-x permissions (the owner can not write). Is this intentional? As a result the blender.app or blenderPlayer.app can not be removed unless the permissions are changed (by running chmod -R u+w). Please note that moving the files to trash by using Finder and the emptying the trash seems to work.

Exact steps for others to reproduce the error
Download the OS X version from the main download site. Unarchive it and try to remove the Blender directory from command line by running rm -rf <path_to_blender>.

Event Timeline

If the files in those directories change the application signature will not be valid.
We need to fix this for next release by moving the python files and caches to a more appropriate path.

Wasn't pre-compiling __pycache__ intentional?, AFAIK these shouldn't have to be re-generated.

They are not regenerated and we generated them intentional.
The permissions on the folders they are in are non writable so they should not be regenerated ever as blender would not be able to write to them anyway.

We should ship the python stuff and extract that to ~/Library/application support on first run and that way keep it out of blender.app's bundle to work around these signing rules better.

Thank you for explaining this. When we deploy Blender to lab machines (or any other OS X machine) the files get copied to /Applications directory and the owner is set to root:wheel recursively. So in mass deployment situations Blender has never had a chance to write inside its own application bundle.

Would these cache files be recreated in some user space temp location if they were missing from the app bundle and user did not have write access to the folder?

Would these cache files be recreated in some user space temp location if they were missing from the app bundle and user did not have write access to the folder?

No, they just won't get created in that case - It will still work, just a little slower startup since Python modules won't be cached.

So it is a real issue to be addressed or more like a TODO?

Sergey Sharybin (sergey) lowered the priority of this task from 90 to Normal.Mar 22 2016, 1:02 PM
Sybren A. Stüvel (sybren) claimed this task.

I'm closing this, as there doesn't seem to be any complaint about this based on how we build/package Blender nowadays.