First time here? Check out the FAQ!
0

SystemError: error return without exception set

I am attempting to use Python with MSC Marc. As I am using "py_send" to open a model file on Marc, I get an error saying "SystemError: error return without exception set". The bottom of the screen reads "General: Document Open Failed:: Failed to open document 'C:\Program Files (x86)\Wing IDE 101 6.0\bin\x-wingide-python-shell:\97113032\2". I am unsure what it all means; I also checked my files and I do not seem to have the specified file location displayed at the bottom of the screen. I do have the py_mentat module imported and thus I do not think it is a module issue.

nl3's avatar
1
nl3
asked 2017-12-04 13:09:00 -0500
Wingware Support's avatar
4.1k
Wingware Support
updated 2019-03-13 10:02:55 -0500
edit flag offensive 0 remove flag close merge delete

Comments

This exception indicates there's a problem in a C extension module.  Do you get it when you run code outside of Wing?

Wingware Support's avatar Wingware Support (2017-12-04 13:15:00 -0500) edit

I tried to run the code through Window Command Prompt but it is unable to recognize the file path location of the py_mentat module, even though I tried to copy the module files to the same file location as the .py file. Thus I run into this problem and the code stops before I can look into this system error problem. I was able to fix this on Wing by specifying the file path.

nl3's avatar nl3 (2017-12-04 14:07:00 -0500) edit

Do you need to specify a PYTHONPATH when running via the Windows Command Prompt?  How do you specify the file path within Wing?

Wingware Support's avatar Wingware Support (2017-12-04 15:04:00 -0500) edit

I specified the file path within Wing by Edit > Configure Python... and specifying the absolute path location of py_mentat.pyd through "Python Path". I have been looking into setting the PYTHONPATH in environment variables but to no success.

nl3's avatar nl3 (2017-12-04 15:27:00 -0500) edit

Try set PYTHONPATH=c:\full\path\name in the Windows Command Prompt window before you run python. 

Wingware Support's avatar Wingware Support (2017-12-04 15:35:00 -0500) edit
add a comment see more comments

1 Answer

0

This exception occurs when there is a bug in a C extension module.  Since this exception occurs outside of Wing, it is probably not related to Wing.  I recommend that you contact the author of the C extension module with a reproducible test case that does not involve Wing and ask them to fix it.

Wingware Support's avatar
4.1k
Wingware Support
answered 2017-12-04 15:50:00 -0500
edit flag offensive 0 remove flag delete link

Comments

add a comment see more comments

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss.

Add Answer