I’m having a problem with Processing in python mode. I added the mode and it went through the installation process, but whether I have code to run or not, when pressing Run button I get:
processing.app.SketchException: ImportError: No module named ast
If there are troubleshooting steps or suggestions, I would appreciate the help. Thanks in advance.
Welcome to the forums, Troy.
What is your system setup? Windows/Mac/Linux? Are you trying to run Processing on some network-mounted drive?
Thank you for replying.
The OS is Windows 10.
It’s a workplace computer, so there are some aspects of it that seem to be dirve mounted and others that are not. I made sure that Processing was located on the C drive as opposed to the desktop. I know the desktop is drive mounted, but not sure what other fecets of this computer environment are.
Python itself is on the C drive in Program Files. Not sure where Java is. I have the JDK_HOME environment variable set up, but there is no java folder in the Program Files directory.
This is exactly my problem. Thank you so much, however, there doens’t appear to be an actual fix.
The ‘Processing’ folder that contained the Python mode was located on a networked drove location. I moved the folder to my C drive in my users directory, but then Processing lost Python mode. I understand that is where it was referencing the mode, but how do I tell it to reference the mode in a new location?
I’ll keep trying to work the issue until I find a solution, otherwise I would greatly benefit from your help.
Again, thank you so much.
I recall encountering this issue a while back when I was using a network account. Unfortunately, I don’t have access to such a setup at the moment, so I cannot test a solution.
As a work-around for now, you could use the command-line version of Processing.py:
You can now use whatever editor you like, including the Processing IDE (provided you compile from the command-line).
if your ?company? computer is professionally secured
following will not work, but it is worth a try:
-a- USB stick ( best USB 3 on USB 3 port )
-b- unzip processing-3.5.3-windows64.zip to it
-c- start processing from there and change Preferences to like
-d- restart processing
-e- install all modes and libs you need again now to USB stick
-f- copy your “sketch work dir” too
-g- test a python example sketch
( if you start that USB stick processing from the company computer
you need first to change preferences again to USB dir
and restart processing.
i just tested all that on a newly setup win10 laptop
please note that processing again will use ( or make new ) its system directory
/Users/ < USER > / AppData/Roaming/Processing
file is ( and also old error logs under /console/ )
/ i have no idea how to FORCE that to the stick too ? /
Thank you both for your feedback. The help has been tremendous.
@kll You hit my issue on the head, I don’t know how to force the install path to something else. I might try a more portable solution like you described, but for now I’m going to go with what I feel is the simpler answer, command line.
@tabreturn I appreciate your assistance. I think you have my solution. I tested out the command line workaround and the program ran, no issue. What I will do is write in the PDE, save, and use the command line to run.