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
Error in version 2.3.0 - "Qt: Could not initialize OLE (error 80010106)" #439
Comments
Minimal reproducible code sample? |
I dont remember changing anything that would affect the thread initialization. An example would be great to figure out when/how this was introduced. |
Though, bug might have been present before from #127 |
@christopherpow if you add these lines before all clr and qt imports - no more OLE error !
I used the suggestion from here: https://mail.python.org/pipermail/pythondotnet/2008-January/000761.html |
curious that the behavior changed though between 2.2.2 and 2.3.0 |
I just tried and I'm getting the same OLE error with 2.2.2 and 2.3.0 without pythoncom |
Most likely this is the same issue as #127. Something else changed and is causing the error that is being manifested as the ole error. something changed between 2.2.2 and 2.3.0 that is causing the exception in #127 that is then manifesting as the ole error. Without a full example we can't really troubleshoot. |
@vmuriart I did not understand your last comment. |
import clr
"""some code"""
from PyQt4 import QtGui The code sample above used to work on pythonnet Without more details from @christopherpow we can't figure it out though. |
I will try to get a minimal example tomorrow. Had to keep moving forward today. |
no worries. Thanks for taking the time and letting us know about it 👍 |
@vmuriart @filmor do you think it is possible to allow initializing CLR from Python under STA COM threading state without using pythoncom: ctypes.windll.ole32.CoInitialize https://msdn.microsoft.com/en-us/library/system.stathreadattribute%28v=vs.110%29.aspx |
@christopherpow Did you manage to build a minimal example? |
closing as reasonable workarounds are provided |
Environment
Details
Describe what you were trying to get done.
Upgrading to latest pythonnet. I have PyQt4 and Python27 working together with pythonnet 2.2.2.
What commands did you run to trigger this issue? If you can provide a
pip uninstall pythonnet
pip install pythonnet
The text was updated successfully, but these errors were encountered: