Add-on's and app-template installation ignores file permissions (execution flag) #73074

Open
opened 2020-01-12 20:05:58 +01:00 by André Ferreira · 7 comments

Extracting zip-files from Python ignores file permissions, see this report .

This causes issues for anyone including executable scripts or binaries in the add-ons.

Extracting the zip on the command line with unzip works as expected.

This task proposes to to support only the executable bit when extracting files, ignoring all other permissions to avoid complications caused by non-default file permissions.


Original Report

System Information
Operating system: macOS Catalina
Graphics card: rx580

Blender Version
Broken: from 2.80 to 2.83

While importing an add-on (animationrender)
GitHub.com/thebadking/animationrender
The binary terminal-notifier gets destroyed and won't work. It will work fine if decompressed manually.

Path: /modules/pync/vendor/terminal-notifier-2.0.0/terminal-notifier.app

Extracting zip-files from Python ignores file permissions, see [this report ](https://bugs.python.org/issue15795). This causes issues for anyone including executable scripts or binaries in the add-ons. Extracting the zip on the command line with `unzip` works as expected. This task proposes to to support only the executable bit when extracting files, ignoring all other permissions to avoid complications caused by non-default file permissions. ---- *Original Report* **System Information** Operating system: macOS Catalina Graphics card: rx580 **Blender Version** Broken: from 2.80 to 2.83 While importing an add-on (animationrender) GitHub.com/thebadking/animationrender The binary terminal-notifier gets destroyed and won't work. It will work fine if decompressed manually. Path: /modules/pync/vendor/terminal-notifier-2.0.0/terminal-notifier.app

Added subscriber: @TheBadKing

Added subscriber: @TheBadKing

Added subscriber: @ideasman42

Added subscriber: @ideasman42

Changed status from 'Needs Triage' to: 'Archived'

Changed status from 'Needs Triage' to: 'Archived'
Campbell Barton self-assigned this 2020-01-13 06:59:51 +01:00

Closing as this isn't part of Blender and there is no evidence this a bug in Blender,
the issue should instead be reported to the add-on.

Closing as this isn't part of Blender and there is no evidence this a bug in Blender, the issue should instead be reported to the add-on.

Did you read the part where I said decompressed manually does not break the binary?

Did you read the part where I said decompressed manually does not break the binary?

Yes, since the report was vague, I didn't think it necessarily pointed to an error in Blender, when 3rd party add-ons are involved, there needs to details about why the issue is with Blender, not the add-on.

Looking into the differences between Python's zipfile support and manually extracting - this is caused by https://bugs.python.org/issue15795 there are some workarounds for this online, however I think we only want the execution mask to be set, since non-default permissions could cause issues later on.

Marking this as a TODO since it could be supported.

Yes, since the report was vague, I didn't think it necessarily pointed to an error in Blender, when 3rd party add-ons are involved, there needs to details about why the issue is with Blender, not the add-on. Looking into the differences between Python's zipfile support and manually extracting - this is caused by https://bugs.python.org/issue15795 there are some workarounds for this online, however I think we only want the execution mask to be set, since non-default permissions could cause issues later on. Marking this as a TODO since it could be supported.

Changed status from 'Archived' to: 'Confirmed'

Changed status from 'Archived' to: 'Confirmed'
Campbell Barton changed title from Blender breaks binary inside of zip file while importing. to Add-on's and app-template installation ignores file permissions (execution flag) 2020-01-14 07:53:24 +01:00
Sign in to join this conversation.
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender-addons#73074
No description provided.