I am using the pythonnet package in MSMQ communications. In my IDE (PyCharm CE), I have the following sample code:
#!/usr/bin/env python3
import pythoncom
import clr
clr.AddReference("System")
clr.AddReference("System.Messaging")
from System import TimeSpan
from System.Messaging import MessageQueue
Aside: this code works fine when I actually run it using Python 3.6.
And below is a screenshot of what it looks like inside PyCharm.
- For
Systemit says:Unresolved reference 'System'
Other than using noqa comments, how can I get my PyCharm linting to do the following:
- Not complain about
from System import XYZ?
Versioning Info
- IDE: PyCharm Community Edition
2019.2 - pythonnet
2.3.0, installed in a virtual environment
