Reinstalling an addon in a zip package won't reload code changes #76248
Labels
No Label
Interest
Animation & Rigging
Interest
Blender Cloud
Interest
Collada
Interest
Core
Interest
Documentation
Interest
Eevee & Viewport
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
Import and Export
Interest
Modeling
Interest
Modifiers
Interest
Nodes & Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds, Tests & Devices
Interest
Python API
Interest
Rendering & Cycles
Interest
Sculpt, Paint & Texture
Interest
Translations
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Meta
Good First Issue
Meta
Papercut
Module
Add-ons (BF-Blender)
Module
Add-ons (Community)
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: blender/blender-addons#76248
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
System Information
Operating system: Microsoft Windows 10 Pro - 10.0.18363 Build 18363 - x64-based PC
Graphics card:
Blender Version
Broken: 2.82 (sub 7), branch: master, commit date: 2020-03-12 05:06, hash: 375c7dc4caf4, type: Release
Short description of error
Reinstalling (remove and install again) an addon in a zip package (
__init__.py
plus some modules) won't reload code changes (errors in console will show the new code, but execute the old code).Tried removing local
__pycache__
contents to no avail.Exact steps for others to reproduce the error
Changes in the addon won't reflect in Blender
Restarting blender will load the changes.
Added subscriber: @leus
Added subscriber: @BrendonMurphy
Changed status from 'Needs Triage' to: 'Confirmed'
Hi I'll triage this as a known issue.
It's been quite longstanding that reload scripts does not handle all cases well.
To correctly identify which cases are not handled will require some testing.
UI changes usually work, changes within classes when bug fixing sometimes work.
Restarting shows all changes, reload scripts can cause false results by "missing" certain changes.
Just in case some plugin developer wants to know, my current workflow is to execute a batch file that zips my project, copies it to the scripts folder, and starts Blender. It's actually quite fast.
Bumping this. Anybody looked at this in the last 3 years?
Seems an easy way to resolve this in source would be to track all paths for modules added, and simply delete those when deleting the addon after unregistering. Including any pycache files. Is that how it's already done?
Hey there @BrendonMurphy just came across a solution that works for me in all my addons with tons of modules:
Perhaps we can fold this into the unregister execution? Is there any reason this might be bad practice?