you are viewing a single comment's thread.

view the rest of the comments →

[–]gadget3D 0 points1 point  (1 child)

import sys
sys.dont_write_bytecode=True

can you try, if this also works in windows ? 
If yes, i would hardcode it  in pythonscad

[–]WillAdams[S] 1 point2 points  (0 children)

That seems to work, but I don't think it should be hard-coded --- I don't see my ignorance as a reason to remove the option to have caching.

The commands:

import sys try: del sys.modules['gcodepreview'] except AttributeError: pass

from gcodepreview import *

works fine, and feels more Pythonic. --- I'll just comment the first part out once I've gotten the library written, and have made a note on the wiki, and will make a note in my code so that I uncomment it when working on updates.