charmap error
I had this error befor, but I manged to fix using firtst Calculix and then the macro, but now this error is back and i don't know how to fix it.
If I see correctly, you use FreeCAD 0.19. Is it ok for you to use newer FreeCAD? Maybe the issue will not be there.
https://youtu.be/7fAHZgM2Syc?feature=shared In this video it says that After 0.19 it's bugged, I tried it and it's true
I managed to make it work but there is again this error
Do you mean with newer FreeCAD version? Which one?
Web search says it could be related to the file encoding, but I do not expect any unusual characters generated by FreeCAD. According to this:
https://stackoverflow.com/questions/9233027/unicodedecodeerror-charmap-codec-cant-decode-byte-x-in-position-y-character
You can modify line 53 in beso_lib.py with a guess of your encoding
f = open(file_name, "r", encoding="utf8")
Supposing that encoding differences are only in the comment lines of the inp file, it could be ok to ignore errors by
f = open(file_name, "r", encoding="utf8", errors="ignore")
or
f = open(file_name, "r", errors="ignore")
Than restart FreeCAD and try to run the optimization macro
Ok, I have found the problem: it appears only when you do a simulation after you have close and savedd the file. Now I have a question: does this macro work with the newest verion?
I used FreeCAD 1.0.0.
Contrary, there is a pull request https://github.com/calculix/beso/pull/28 waiting with minor code revision that will not work with older than FreeCAD 0.20.1.