Nodes Object field still contains object after actual object is deleted #81712
Labels
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
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
4 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: blender/blender#81712
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
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: Windows-10-10.0.18362-SP0 64 Bits
Graphics card: GeForce GTX 1050 Ti/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 456.55
Blender Version
Broken: version: 2.90.0, branch: master, commit date: 2020-08-31 11:26, hash:
0330d1af29
Worked: (newest version of Blender that worked as expected)
Short description of error
Exact steps for others to reproduce the error
Object
field. In node field object is still alive.nodes_bug.blend
Added subscriber: @ivpe
Update: just to play with: after exact steps open blend file view mode in outliner and select deleted object. Than press NUM "." in the viewport and become confused much more.
Added subscribers: @Sergey, @mano-wii
Thanks for the report,
I can confirm and I agree that it is strange, but as that is a
'POINTER'
property, this behavior is kind of expected :What happens is that
'POINTER'
properties add a reference to the object. They work almost like aFake User
.So the object is not really deleted, it remains saved in the file until this reference is removed.
Perhaps this property could be of type
'STRING'
, so this problem would be solved since only the name would matter.This feature was introduced in
df07a25d
@Sergey, would changing the type of this property to
'STRING'
be a good change?@mano-wii thank you for quick answer! Actually, I think this bug may be much more deeper. I found it while trying to solve issues with my own project (#81662 ) while searching for
BKE_libblock_unlink
call stack. ThereObject*
pointers behave in the same way as here, keeping deleted object pointer. And I think that same behaviour may be in much more other places. So I hope for more deeper solution than replacing pointer to name/also if I will have a bit more time, I will do it by myself (but currently all I can do - just report an issue;))Added subscribers: @mont29, @lichtwerk
Changed status from 'Needs Triage' to: 'Confirmed'
@mano-wii: dont think changing this to a string would be good (breaks on renaming)
The deleted object will be removed from all scenes, collections, constraints usage on other objects, modifiers usage on other objects, ... more... but not materials on other objects.
Constraints and modifiers happens more or less automatically because these dont increase usercount - which means that when the object is deleted, it reaches zero users -- and will be gone completely.
I am a bit surprised that usage inside materials increases usercount, whereas usage inside constraints and modifiers doesnt.
If the usercount does not decrease for the material usage, the object does not reach zero users and thus will not be gone completely but kept instead.
This is probably a (design) question that @mont29 can answer best [but will confirm the behaviour for now -- even though this is probably by design]
Users can be checked with this snippet btw:
Changed status from 'Confirmed' to: 'Archived'
There is no bug here, if you want to fully nuke an object use
shift-X
(Delete Global) option.After all this time, I still wasnt aware of this one! Thx for the heads up!
Yes, thats works!) I looked at documentation and (it was only just my own opinion) maybe it should be documented here?
https://docs.blender.org/manual/en/dev/scene_layout/object/editing/delete.html
Good point, done, thanks