Python: operator macros cause a crash #83851

Closed
opened 2020-12-16 15:57:56 +01:00 by Stanislav Blinov · 7 comments

System Information
Operating system: Linux 5.9.10-arch1-1

Blender Version
Broken: 2.91, 2.92 master
Worked: 2.90.1

Caused by 7447eb7e74.

Short description of error

Attempting to invoke a macro defined in Python crashes Blender.

Exact steps for others to reproduce the error

Switch to the Scripting workspace, create new text block, paste this example code and run it:

import bpy

class TestMacro(bpy.types.Macro):
    bl_idname = "object.test_macro"
    bl_label = "TestMacro"
    
def register():
    bpy.utils.register_class(TestMacro)
    TestMacro.define("OBJECT_OT_select_all")
    
if __name__ == "__main__":
    register()

In 3D view, open the search menu, search for "TestMacro" and invoke it.

**System Information** Operating system: Linux 5.9.10-arch1-1 **Blender Version** Broken: 2.91, 2.92 master Worked: 2.90.1 Caused by 7447eb7e74. **Short description of error** Attempting to invoke a macro defined in Python crashes Blender. **Exact steps for others to reproduce the error** Switch to the Scripting workspace, create new text block, paste this example code and run it: ``` import bpy class TestMacro(bpy.types.Macro): bl_idname = "object.test_macro" bl_label = "TestMacro" def register(): bpy.utils.register_class(TestMacro) TestMacro.define("OBJECT_OT_select_all") if __name__ == "__main__": register() ``` In 3D view, open the search menu, search for "TestMacro" and invoke it.

Added subscriber: @Stan_Pancakes

Added subscriber: @Stan_Pancakes
Member

Added subscriber: @lichtwerk

Added subscriber: @lichtwerk
Member

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

Changed status from 'Needs Triage' to: 'Confirmed'
Member

Can confirm, will check

Can confirm, will check
Philipp Oeser self-assigned this 2020-12-16 16:12:10 +01:00

This issue was referenced by 13530e83f0

This issue was referenced by 13530e83f0aa15931839395a2f63e14aef899b4b

This issue was referenced by ebd8a703cc

This issue was referenced by ebd8a703ccb6b8884b26e78771a9fec8ba919f9a
Member

Changed status from 'Confirmed' to: 'Resolved'

Changed status from 'Confirmed' to: 'Resolved'
Sign in to join this conversation.
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
3 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#83851
No description provided.