loopcut_init crashes in background in view3d_operator_needs_opengl #112083

Closed
opened 2023-09-07 15:00:25 +02:00 by Muhammad Abubakar Irshad · 6 comments

System Information
Operating system: Microsoft Windows 11 Home

Graphics card: Intel(R) UHD Graphics OK

I am trying To run Python file in background but it is giving error, but without background it works fine and script works.I have shared file and simlar issue is already posted but it didn't work for me

**System Information** Operating system: Microsoft Windows 11 Home Graphics card: Intel(R) UHD Graphics OK I am trying To run Python file in background but it is giving error, but without background it works fine and script works.I have shared file and simlar issue is already posted but it didn't work for me
Muhammad Abubakar Irshad added the
Priority
Normal
Type
Report
Status
Needs Triage
labels 2023-09-07 15:00:26 +02:00
Muhammad Abubakar Irshad changed title from Blender 3.6.2 ExceptionCode : EXCEPTION_ACCESS_VIOLATION to Blender 3.6.2 ExceptionCode : EXCEPTION_ACCESS_VIOLATION 2023-09-07 15:03:41 +02:00
Member

Looks like you are trying to call loop cut operator and that operator requires the user interface to run correctly.

If no user interaction is needed, or the argument made it so that the loop cut operator does not read anything from the viewport, there is then a chance we could improve on the operator to eliminate the need for viewport on that execution path.

Could you share the script file you are trying to run this in background? That way we can get an better idea of what it's supposed to be doing. Thanks!

Looks like you are trying to call loop cut operator and that operator requires the user interface to run correctly. If no user interaction is needed, or the argument made it so that the loop cut operator does not read anything from the viewport, there is then a chance we could improve on the operator to eliminate the need for viewport on that execution path. Could you share the script file you are trying to run this in background? That way we can get an better idea of what it's supposed to be doing. Thanks!
YimingWu added
Status
Needs Information from User
and removed
Status
Needs Triage
labels 2023-09-08 04:08:03 +02:00
YimingWu changed title from Blender 3.6.2 ExceptionCode : EXCEPTION_ACCESS_VIOLATION to `loopcut_init` crashes in background in `view3d_operator_needs_opengl` 2023-09-08 04:08:55 +02:00
Member

Looks like view3d_operator_needs_opengl(C) call isn't enclosed inside is_interactive in loopcut_init(). Moving it inside should mitigate the issue.

Looks like `view3d_operator_needs_opengl(C)` call isn't enclosed inside `is_interactive` in `loopcut_init()`. Moving it inside _should_ mitigate the issue.

@ChengduLittleA Thank You for your kind consideration. Thats true that we are using loop cut operator in the script.I have attached script.This Script makes a simple tyre with treads. iT works fine on UI Script but not on background. It also saves the result to output path which i have hard coded to my directory.

@ChengduLittleA Thank You for your kind consideration. Thats true that we are using loop cut operator in the script.I have attached script.This Script makes a simple tyre with treads. iT works fine on UI Script but not on background. It also saves the result to output path which i have hard coded to my directory.

Looks like view3d_operator_needs_opengl(C) call isn't enclosed inside is_interactive in loopcut_init(). Moving it inside should mitigate the issue.

I'm Beginner in Blender scripting Can you Kindly give me some hint that how can I achieve this in above script.A lot of code is just what blender info panel produced of an action.

> Looks like `view3d_operator_needs_opengl(C)` call isn't enclosed inside `is_interactive` in `loopcut_init()`. Moving it inside _should_ mitigate the issue. I'm Beginner in Blender scripting Can you Kindly give me some hint that how can I achieve this in above script.A lot of code is just what blender info panel produced of an action.
Member

@Muhammad-Abubakar-2 Hi, thanks for the script. This requires fixing in blender internally, you don't need to personally do anything.

@Muhammad-Abubakar-2 Hi, thanks for the script. This requires fixing in blender internally, you don't need to personally do anything.
Blender Bot added
Status
Resolved
and removed
Status
Needs Information from User
labels 2023-09-18 15:45:27 +02:00

@ChengduLittleA Hi!
How can I fix it Now?

@ChengduLittleA Hi! How can I fix it Now?
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
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#112083
No description provided.