Closed charredUtensil closed 1 year ago
Same message for me :_(
So after more testing, I believe this is a misleading error message, and the cause is actually SpoolManager failing to compute filament usage in the gcode file. The reason I think that is I have one gcode file that always generates the error: It's for leveling the print bed. It doesn't doesn't extrude any filament or heat up the nozzle.
I'm not very familiar with this codebase, but the error seems to be decided here: https://github.com/OllisGit/OctoPrint-SpoolManager/blob/dea8d64c1849c970f3616e158260c4c6fef5a4b7/octoprint_SpoolManager/api/SpoolManagerAPI.py#L378
i have the same effect. some gcode work and newest one not. i changed to the latest prusa-slicer version, maybe something changed in the gcode. Or maybe some settings in the slicer?
I can also consistently reproduce this bug by uploading a different gcode file with the same name (overwrite) and then immediately printing it. After a few minutes and a few failed prints, SpoolManager eventually stops complaining and behaves normally.
I can reproduce it as follows:
spool manager will say:
ATTENTION: Needed filament could not calculated (missing metadata or spool-fields)
There are no spools selected for the following tools despite them being used (maybe) by this print:
- Tool 0
- Tool 1
Do you want to start the print without selected spools?
In contrast if i wait until the fie has been analyzed the pre-selected spool is chosen as expected.
Since i have larger files to print and OP is running on a BananaPi, it may take ages until the file is processed. Thus i wish i could disable "Settings -> Features -> Features -> Analyze gcode for time and model size estimates -> Never". But disabling this feature with OctoPrint: 1.8.7
+ Spool Manager: 1.7.0
will never allow me to select any spool (as described above).
Suggestion: If the user starts a print of a file that has not been analyzed so far, still allow the user to start the print with the preselected spool.
Workaround: Leave file analysis enabled and wait until OP reports the Approx. Total Print Time:
as "xx minutes" instead of "-". This is an indicator that the file processing has finished.
This issue has been automatically marked for closing, because it has not had activity in 30 days. It will be closed if no further activity occurs in 10 days.
This issue was closed, because it has been already marked for 10 days with no activity.
A print finished as normal. I went to do a print the next day and was confronted with this dialog:
As you can see, the spool "Mint" is still selected below. I didn't change the spool, any settings on the spool, or even turn off the printer. The only thing that's changed from the successful print yesterday is that I uploaded this new gcode file. I tried deselecting and reselecting the spool, and that appears to function normally. The server log also seems to think it was successful:
There are no errors in the JS console either. In the "spools" tab, all the settings still appear to be present and correct:![Screenshot_2023-03-16_13-47-18](https://user-images.githubusercontent.com/1398543/225708995-0b9333dc-9e7f-4e38-bfce-3967d9007698.png)
Did the same happen when all other 3rd party plugins are disabled? The only other plugin I had installed was Consolidated Tabs. Disabling it did not help. Everything else is from a stock OctoPi image.
Log file
I also tried restarting the entire computer multiple times, but this didn't resolve it. However, once the print finished, the total remaining filament updated correctly - and then I was able to print several more things without this reproducing.
Screenshots Inline
Additional context I recently switched from FilamentManager to SpoolManager but this is the first time I'm seeing this issue. Again, I changed absolutely nothing from yesterday when this was working fine. My hunch is that maybe this doesn't work if the backend isn't done analyzing the file, and the error message is just confusing?