Problem with 'import pyesapi'
maksymfritsak opened this issue · comments
Hello,
Installation was without any errors. However, when I run "import pyesapi" the following exception pops up:
Exception Traceback (most recent call last)
Cell In[2], line 1
----> 1 import pyesapi
2 #import atexit
3 #app = pyesapi.CustomScriptExecutable.CreateApplication('python_demo')
4 #atexit.register(app.Dispose);
File ~\AppData\Roaming\Python\Python311\site-packages\pyesapi_init_.py:44
41 paths = [os.path.join(drive, os.sep, base, ver, rp) for rp in rpaths]
43 if len(paths) < 2:
---> 44 raise Exception("Did not find required library paths! Searched for:\n %s" % (",\n".join(searched_paths)))
45 if len(paths) > 2:
46 print("WARNING: Found multiple possible VMS dll locations:\n %s" % (",\n".join(paths)))
Exception: Did not find required library paths! Searched for:
C:\Program Files (x86)\Varian\RTM%version\esapi\API,
C:\Program Files (x86)\Varian\RTM%version\ExternalBeam,
D:\Program Files (x86)\Varian\RTM%version\esapi\API,
D:\Program Files (x86)\Varian\RTM%version\ExternalBeam
How one can solve this?
Best wishes,
Maksym
PyESAPI is pythonnet wrapper over ESAPI/Eclipse and requires Eclipse installation to work. The exception tells that PyESAPI cannot find the requisite libraries in expected locations so try on machine with Eclipse installation at hand. ESAPI alone will not cut it because ESAPI, which is UI-less Eclipse client with some restrictions, relies on Eclipse proper.