Closed jessemillar closed 2 years ago
The log file is the main octoprint.log
. You'll probably see an error rendering the script output.
I haven't designed it to take in the same context as the rest of the gcode scripts, although I can see how that might be useful to have for things like smart preheat. I will look at the feasibility (there may be a simple thing I can import and use) of putting the same context into these scripts.
I've done some research into the possibility of adding this context to these gcode macros here, and have decided that it is not feasible to try and get other plugin's context into the gcode macros.
The OctoPrint hooks to get the extra variables are for the built in gcode scripts, I can't really support everything that would be expected there, and so it would be a messy hack. In the case of 'Smart Preheat', it specifically only reads the temperatures in beforePrintStarted
, though maybe they are available everywhere after that is run.
Totally understandable. Thanks for looking into it!
I'm attempting to port some GCODE into a macro. My GCODE commands use Jinja2 to access values from other plugins. Works fine when I have the same GCODE in the Octoprint "GCODE Scripts" section but when I try to run my macro after defining it in GcodeMacros, it just doesn't run. I don't see any GCodeMacros log files and there's no terminal output when I try to run my macro.