Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Receive error when saving project after using LC Interlocking features. #67

Open
TsetTsyung opened this issue May 14, 2024 · 1 comment

Comments

@TsetTsyung
Copy link

TsetTsyung commented May 14, 2024

Hi all - please bear with me. My GitHub experience is minimal.

FreeCAD Version: 0.21.2
LCInterlocking Version: Up-To-Date (Unknown Version)

After using the 'Living Hinge' module to make a living hinge and attempting to save the project, I receive the following error:

09:14:14  PropertyPythonObject::toString(): failed for 
09:14:14  Traceback (most recent call last):
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\__init__.py", line 231, in dumps
    return _default_encoder.encode(obj)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 199, in encode
    chunks = self.iterencode(o, _one_shot=True)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 257, in iterencode
    return _iterencode(o, 0)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 179, in default
    raise TypeError(f'Object of type {o.__class__.__name__} '
: Object of type HingesProperties is not JSON serializable
09:14:14  PropertyPythonObject::toString(): failed for 
09:14:14  Traceback (most recent call last):
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\__init__.py", line 231, in dumps
    return _default_encoder.encode(obj)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 199, in encode
    chunks = self.iterencode(o, _one_shot=True)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 257, in iterencode
    return _iterencode(o, 0)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 179, in default
    raise TypeError(f'Object of type {o.__class__.__name__} '
: Object of type ViewProviderDocumentObject is not JSON serializable

When attempting to save after using the Tabs feature, I receive this error message:

09:22:59  PropertyPythonObject::toString(): failed for 
09:22:59  Traceback (most recent call last):
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\__init__.py", line 231, in dumps
    return _default_encoder.encode(obj)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 199, in encode
    chunks = self.iterencode(o, _one_shot=True)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 257, in iterencode
    return _iterencode(o, 0)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 179, in default
    raise TypeError(f'Object of type {o.__class__.__name__} '
: Object of type TabProperties is not JSON serializable
09:22:59  PropertyPythonObject::toString(): failed for 
09:22:59  Traceback (most recent call last):
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\__init__.py", line 231, in dumps
    return _default_encoder.encode(obj)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 199, in encode
    chunks = self.iterencode(o, _one_shot=True)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 257, in iterencode
    return _iterencode(o, 0)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 179, in default
    raise TypeError(f'Object of type {o.__class__.__name__} '
: Object of type MaterialProperties is not JSON serializable
09:22:59  PropertyPythonObject::toString(): failed for 
09:22:59  Traceback (most recent call last):
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\__init__.py", line 231, in dumps
    return _default_encoder.encode(obj)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 199, in encode
    chunks = self.iterencode(o, _one_shot=True)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 257, in iterencode
    return _iterencode(o, 0)
  File "C:\Program Files\FreeCAD 0.21\bin\lib\json\encoder.py", line 179, in default
    raise TypeError(f'Object of type {o.__class__.__name__} '
: Object of type ViewProviderDocumentObject is not JSON serializable

In both situations, the project does actually save, but the above messages are posted into the console (originally making me think it wasn't saving...)

Hopefully this information is of use. Thank you for your work on this awesome and extremely useful module.

Mike

@TsetTsyung
Copy link
Author

TsetTsyung commented May 14, 2024

[FACEPALM] - I have no idea why the formatting of the error message got butchered. G2G right now, but will research how to properly format and will update/post new messages upon my return.

UPDATE: Updated original content to use "[<]pre[>][<]code[>]---[<]/code[>][<]/pre[>]" instead of the usual backticks. Hopefully this doesn't screw up the visualisation for anyone.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant