Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

class ‘PythonQtScriptingConsole’ doesn't work well after multithreading is enabled #40

Open
dawnrs opened this issue Feb 26, 2021 · 1 comment
Labels
question Further information is requested

Comments

@dawnrs
Copy link

dawnrs commented Feb 26, 2021

I found that when I enable multithreading support, I have to apply macro ‘PYTHONQT_GIL_SCOPE’ to the whole message loop to make class ‘PythonQtScriptingConsole’ work well.
In general, this seems OK, but when I wanted to use macro 'PYTHONQT_ALLOW_THREADS_SCOPE' when the console was running, I found that I couldn't solve the problem.
As you know, when macro 'PYTHONQT_GIL_SCOPE' exists, macro 'PYTHONQT_ALLOW_THREADS_SCOPE' is temporarily disabled.
Therefore, when the class ‘PythonQtScriptingConsole’ does not execute any code at this time, the python thread created previously will not have a chance to be executed.
So I think if class ‘PythonQtScriptingConsole’ can support multithreading, class ‘PythonQtScriptingConsole’ will be better.

@YuDe95
Copy link

YuDe95 commented Aug 11, 2021

Have you solved the problem?

@mrbean-bremen mrbean-bremen added the question Further information is requested label Dec 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants