Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Externally stopping/cancelling a print job not registering in OctoPrint #42

Closed
johnc2k opened this issue Sep 2, 2024 · 7 comments
Closed
Labels
bug Something isn't working

Comments

@johnc2k
Copy link

johnc2k commented Sep 2, 2024

  • Octoprint: 1.10.2 (Docker Container)
  • OctoPrint-BambuPrinter: 0.1.3
  • Bambu P1S: 01.06.01.00

When stopping/cancelling a print job externally from OctoPrint (e.g. via Bambu Studio), OctoPrint does not register the print as stopped/cancelled and remains stuck on Printing from SD.

Stopping/cancelling from Octoprint works fine.

plugin_bambu_printer_serial.log
octoprint.log

@jneilliii
Copy link
Owner

octoprint.log

2024-09-02 14:38:29,142 - octoprint.util.comm - INFO - Cancelling job on behalf of user admin
2024-09-02 14:38:29,142 - octoprint.util.comm - INFO - Changing monitoring state from "Printing from SD" to "Cancelling"
2024-09-02 14:38:29,143 - octoprint.printer.standard.job - INFO - Print job cancelled - origin: sdcard, path: 3DBenchy.gcode.3mf, owner: None, user: admin, fileposition: 179850, position: {'t': None, 'f': None, 'z': None, 'y': None, 'x': None, 'e': None}

I think it's picking up the cancel, but then never resets the messages being sent to OctoPrint back to Not SD Printing.

2024-09-02 14:38:32,067 - octoprint.plugins.bambu_printer.BambuPrinter - DEBUG - Received printer state update: FAILED

I should be able to know this needs resetting from this state update.

BTW, I notice commands being sent after the cancel. You may want to remove any commands from OctoPrint's GCODE Scripts section to prevent any issues.

@jneilliii jneilliii added the bug Something isn't working label Sep 2, 2024
@jneilliii
Copy link
Owner

I think I have this fixed in the above commit/branch. If you don't mind testing it out for me that would be greatly appreciated. Go into Plugin Manager > Get More, and at the bottom copy/paste this URL into ...from URL and click install. No need to uninstall first, but if not prompted to restart OctoPrint make sure to do that.

https://github.com/jneilliii/OctoPrint-BambuPrinter/archive/refs/heads/bugfix/external_cancel.zip

@johnc2k
Copy link
Author

johnc2k commented Sep 3, 2024

Unfortunately the same issue is still occurring

plugin_bambu_printer_serial.log
octoprint.log

@jneilliii
Copy link
Owner

I just noticed something additional in both serial logs. The file being currently printed is not being picked up in the file list? Can you share how you are starting the file and if you are running cloud connected or not for the plugin and printer?

2024-09-03 09:29:21,406 >>> Begin file list
2024-09-03 09:29:21,406 >>> articu~1.3mf 2032589 0x58bb8762 "Articulated_Slug-round_tail.gcode.3mf"
2024-09-03 09:29:21,417 >>> lead-s~1.3mf 2026748 0x59218709 "lead-screw-shield-v2.3mf"
2024-09-03 09:29:21,417 >>> End file list
...
2024-09-03 09:28:52,721 >>> File opened: 3DBenchy.gcode.3mf  Size: 1789634
2024-09-03 09:28:52,721 >>> File selected
...
2024-09-02 14:09:54,638 >>> Begin file list
2024-09-02 14:09:54,639 >>> articu~1.3mf 2032589 0x58bb8762 "Articulated_Slug-round_tail.gcode.3mf"
2024-09-02 14:09:54,652 >>> short_~2.3mf 21059949 0x5917aa91 "Short Grip.gcode.3mf"
2024-09-02 14:09:54,652 >>> End file list
...
2024-09-02 14:10:30,212 >>> File opened: 3DBenchy.gcode.3mf  Size: 2248129
2024-09-02 14:10:30,212 >>> File selected

@johnc2k
Copy link
Author

johnc2k commented Sep 4, 2024

Ah yes thats my fault, I trimmed down the filename list for privacy.

I have tried the printer in both Cloud and LAN Only mode.
The above logs were both in LAN Only mode sent from Bambu Studio

jneilliii added a commit that referenced this issue Sep 4, 2024
@jneilliii
Copy link
Owner

ok, thanks that makes more sense. I think I actually was able to resolve this issue for real and have tested myself. If you follow the same steps as before to install with ..from URL field in Plugin Manager I think it should be working as expected again.

@johnc2k
Copy link
Author

johnc2k commented Sep 4, 2024

Yep that fixed it, many thanks

@jneilliii jneilliii mentioned this issue Sep 4, 2024
jneilliii added a commit that referenced this issue Sep 4, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
* fix stuck Printing from SD state when canceled in slicer or on printer, #42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants