Please help. Can not get it working with Python.

524 views
Skip to first unread message

Jonathan Moshe

unread,
Feb 11, 2022, 11:58:46 AM2/11/22
to OpenVSP
Hi Rob, I have the latest version of OpenVSP and it is working okay except when trying to do some Python stuff with it.

I discovered this originally when trying to export VSP geometry from SUAVE. But in troubleshooting (without SUAVE), here's what I've tried and found...

(FYI, I'm running Windows 10 with Python 3.9.10)

I ran 'OpenVSP-3.26.1-win64-Python3.9\OpenVSP-3.26.1-win64\python\openvsp.setup.py'

Next, I tried running, 'C:\OpenVSP-3.26.1-win64-Python3.9\OpenVSP-3.26.1-win64\python\openvsp\openvsp\tests\test.py'

I'm getting the following error...

Traceback (most recent call last):
  File "C:\OpenVSP-3.26.1-win64-Python3.9\OpenVSP-3.26.1-win64\python\openvsp\openvsp\tests\test.py", line 4, in <module>
    import openvsp as vsp
  File "C:\Users\jmoshe\AppData\Local\Programs\Python\Python39\lib\site-packages\openvsp-3.26.1-py3.9.egg\openvsp\__init__.py", line 1, in <module>
    from .vsp import *
  File "C:\Users\jmoshe\AppData\Local\Programs\Python\Python39\lib\site-packages\openvsp-3.26.1-py3.9.egg\openvsp\vsp.py", line 13, in <module>
    from . import _vsp
ImportError: cannot import name '_vsp' from partially initialized module 'openvsp' (most likely due to a circular import) (C:\Users\jmoshe\AppData\Local\Programs\Python\Python39\lib\site-packages\openvsp-3.26.1-py3.9.egg\openvsp\__init__.py)

Any ideas how to fix?
Thanks!
-Jonathan-

Jonathan Moshe

unread,
Feb 16, 2022, 5:11:01 PM2/16/22
to OpenVSP
I'm still unable to run the test.py script after a few more attempts this week.  Any suggestions, perhaps I missed a step somewhere?
Thanks!

Brandon Litherland

unread,
Feb 17, 2022, 9:09:34 AM2/17/22
to OpenVSP
Let's see... Are you building the API from a Windows Conda PowerShell or in python itself?  I've had a few attempts result in a failed build because I wasn't using the Conda PowerShell to run setup.ps1.  Based on your command, I'd say you should try running the pip install requirements-dev.txt (this probably isn't exactly the correct command but you can find it in the setup.ps1 file or the readme) in the python 3.9 console.

Jonathan Moshe

unread,
Feb 17, 2022, 4:10:22 PM2/17/22
to OpenVSP
Thank you!  I was able to get it working with your help. 
Reply all
Reply to author
Forward
0 new messages