Opened 4 years ago
Last modified 3 years ago
#6147 assigned defect
OpenModelica 1.16.0-dev.beta1-64bit OMPython Install Problem
Reported by: | anonymous | Owned by: | Adeel Asghar |
---|---|---|---|
Priority: | blocker | Milestone: | 1.19.0 |
Component: | OMPython | Version: | v1.16.0-dev |
Keywords: | Cc: | arunkumar palanisamy |
Description
Following the directions at https://github.com/OpenModelica/OMPython
Windows 10
Python 3.7.9
Latest pip 20.2.3
Just downloaded OpenModelica Wednesday, September 30.
c:\Program Files\OpenModelica1.16.0-dev.beta1-64bit\share\omc\scripts\PythonInterface>python -m pip install -U
ERROR: You must give at least one requirement to install (see "pip help install")
Command Prompt - Regular user or Administrator - same result.
It was working with 1.14.
Change History (10)
comment:1 by , 4 years ago
Component: | *unknown* → OMPython |
---|---|
Milestone: | Future → 1.16.0 |
Owner: | changed from | to
Priority: | high → blocker |
Status: | new → assigned |
Type: | discussion → defect |
comment:2 by , 4 years ago
Cc: | added |
---|---|
Owner: | changed from | to
I think is Adeel or Arun that know how OMPython installs on Windows.
comment:3 by , 4 years ago
The path is wrong, you should go to the following location "C:/Program Files/OpenModelica1.16.0-dev.beta1-64bit/share/omc/scripts/PythonInterface/OMPython" and open the command prompt in administrator mode and do the following
>>> cd C:/Program Files/OpenModelica1.16.0-dev.beta1-64bit/share/omc/scripts/PythonInterface/OMPython >>> python setup.py install
OR
since you already have pip installed, just from the command prompt run
>>> pip install OMPython
This should also work.
comment:4 by , 4 years ago
Still not there yet. "help(OMPython" works as before. Then do:
import OMPython
from OMPython import OMCSessionZMQ
omc = OMCSessionZMQ()
2020-10-02 09:12:14,683 - OMPython - ERROR - OMC Server is down. Please start it! Log-file says:
'C:\Program' is not recognized as an internal or external command,
operable program or batch file.
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Users\xxx\AppData\Local\Programs\Python\Python37\lib\site-packages\OMPython\init.py", line 545, in init
self._connect_to_omc(timeout)
File "C:\Users\xxx\AppData\Local\Programs\Python\Python37\lib\site-packages\OMPython\init.py", line 568, in _connect_to_omc
raise Exception("OMC Server is down. Could not open file %s" % self._port_file)
Exception: OMC Server is down. Could not open file C:/Users/xxx/AppData/Local/Temp/openmodelica.port.5201c995797a4cd482e0770b5eb65b8a
comment:7 by , 4 years ago
Is there a chance you just missed the .
(dot) in
c:\Program Files\OpenModelica1.16.0-dev.beta1-64bit\share\omc\scripts\PythonInterface>python -m pip install -U
it should be
c:\Program Files\OpenModelica1.16.0-dev.beta1-64bit\share\omc\scripts\PythonInterface>python -m pip install -U .
But I installed OMPython a week ago (v1.17-dev and v1.18-dev) and it worked fine for me running it from Python 3.8 from Anaconda.
It could also be that you will need Python 3.8 (you seem to be using 3.7) for some function to open dll's.
comment:8 by , 4 years ago
Milestone: | 1.17.0 → 1.18.0 |
---|
Retargeted to 1.18.0 after 1.17.0-dev.beta2 release
This is top priority. @sjoelund.se, could you have a look, please?