Open hebaoxing opened 7 years ago
Calling on @awhiemstra also... I have no clue about this.
I've seen this when mixing wrong (old) versions of Arcus with newer Cura versions. Where older Arcus was wrongly in my path.
thanks for the replies! @Ghostkeeper @daid
@daid Is there something i can do to build Cura smoothly with Arcus? or the newer version Arcus is a must? and where i can get the newer version Arcus? thanks!
The newer version of Arcus is here in this repo, but if you installed an older version in your python installation, then the newer version does not properly override this.
@daid
based this repo, the newer version Arcus, now i can get Arcus.pyd built by VS2015. i copy the file Arcus.pyd and Arcus folder(including init.py, *.sip files) to the python folder ..\Lib\site-packages, then do 1) python; 2)import Arcus; 3)print(Arcus.file); get: ..\Lib\site-packages\Arcus__init__.py.
is there something wrong about what i do ? install Arcus means what operations? thanks!
You only need the .pyd file. The other files are leftovers that should have been removed a long time ago. I just removed them.
The .pyd should be placed somewhere where your Python can find it, either by setting PYTHONPATH or by manually copying the file.
@awhiemstra @daid
i copy the .pyd file to the python folder ..\Lib\site-packages, and set PYTHONPATH to ..\Lib\site-packages, but when i build the cura project, the error"AttributeError: module 'Arcus' has no attribute 'SocketListener'" still appears, how can i solve this error? thanks!
Make sure there is no "Arcus" directory in any of the PYTHONPATH directories. Python will try and load that directory before loading the .pyd file and then fail because the old Python implementation does not match the newer API.
@awhiemstra
Arcus is not in any of the PYTHONPATH directories, just copy the .pyd file to the python folder.
I put the UM and Arcus folder in the cura project, if not, the compile will not find module Arcus and UM. but still can't avoid the error "AttributeError: module 'Arcus' has no attribute 'SocketListener'". it seems the compiler is not easy to find the SocketListener in every kind of try.
In that case, it is finding the Arcus folder in the Cura folder. You need to remove that one and make sure the only Arcus thing Python can find is Arcus.pyd.
i remove the Arcus folder, but the UM can't find it.
SingalSocket.py in the UM folder import Arcus
errors:
...
cura.CrashHandler.show [35]: "../CuraMaster\UM\Backend\SignalSocket.py", line 4, in
The "DLL load failed" is the relevant message here. For some reason, the .pyd fails to load. Please post the entire stack trace.
"C:\Python 3.5\python.exe" "C:\Program Files (x86)\JetBrains\PyCharm 2016.3\helpers\pydev\pydevd.py" --multiproc --qt-support --client 127.0.0.1 --port 7256 --file D:/XProject/Cura/20170102/CuraMaster/cura_app.py pydev debugger: process 1052 is connecting
Connected to pydev debugger (build 163.8233.8)
cura.CrashHandler.show [32]: An uncaught exception has occurred!
cura.CrashHandler.show [35]: Traceback (most recent call last):
cura.CrashHandler.show [35]: File "C:\Program Files (x86)\JetBrains\PyCharm 2016.3\helpers\pydev\pydevd.py", line 1596, in
Process finished with exit code 1
@awhiemstra is there some idea about entire stack? i can't still find some solution about this issue.
The module is not in the .pyd file or something? :confused:
@Ghostkeeper thanks! the Arcus.pyd file is successfully compiled out. i copy the .pyd file to the python folder ..\Lib\site-packages, the Arcus module should be in the *.pyd file, but i have no tool to check. i think it seems Cura can't find the .pyd file.
if there is a fool-style way for the cura to link Arcus, the third party developer don't need to care the setting or install, it will be better.
print(Arcus.file)
We need arcus file. Dont delete it
@Ghostkeeper @daid @fabianrodrigo
i'am also encountering the issue "No attribute SocketListener". and commands:
get: somethingsomething/python3.5/lib/site-packages/Arcus/init.py
the big trouble for me is: i don't know how to build the libArcus on the windows, so the file Arcus.pyd can't be generated out. when i follows the build guidelines about Arcus on the webpage, also guideline about protobuf, they are no effective when i try to compile or install, every compile path is full of errors.
Could you point me out more detailed compile or install procedures? many thanks!