r/OpenPythonSCAD • u/MoaiJeff • Mar 19 '25
import python math in openpythonSCAD
Having trouble with a simple package import. Read through some other threads and still can't get it to work. import math
Installed: OpenSCAD-silicon-2025-01-30
Had python 3.12 installed, but couldn't import math, appended sys.path, but no luck
Installed python 3.13, and included the path in my sys.path and zshrc file.
Any ideas?
4
Upvotes
View all comments
Show parent comment
1
u/MoaiJeff Mar 25 '25
The rest of the file was commented out. Here it is by itself.
from openscad import *
cu = cube([5,5,5])
cy = cylinder(5)
fusion = cu | cy
show(fusion)
give the error:
ERROR: Exception ignored in PyObject_HasAttrString(); consider using PyObject_HasAttrStringWithError(), PyObject_GetOptionalAttrString() or PyObject_GetAttrString():
Traceback (most recent call last):
File "<string>", line 3, in <module>
AttributeError: module '__main__' has no attribute 'fs'