Commit Graph
1156 Commits
Author SHA1 Message Date
MartinNYHC f021de64dd Merge branch '0.2.0b' into main 2026-02-13 16:05:18 +01:00
maziggy 86a2bb2400 Sync 2026-02-13 16:00:59 +01:00
maziggy d9a701fe8e Sync 2026-02-13 15:57:01 +01:00
MartinNYHC ffdb618d05 Merge pull request #359 from Keybored02/0.2.0b
Add soft-delete support for system maintenance types
2026-02-13 15:56:19 +01:00
DevZwF 740977241f updated translation file. 2026-02-13 09:52:57 -05:00
Keybored 79f68a2a40 Merge branch 'maziggy:0.2.0b' into 0.2.0b 2026-02-13 15:42:41 +01:00
Matteo Parenti c40447b5f9 Merge branch '0.2.0b' of https://github.com/Keybored02/bambuddy into 0.2.0b 2026-02-13 15:40:05 +01:00
Matteo Parenti 8b0895f63f Add soft-delete for system maintenance tasks 2026-02-13 15:39:52 +01:00
MartinNYHC 0b734113cf Merge pull request #357 from Keybored02/0.2.0b
Add filament type and color to R nozzle hover card
2026-02-13 15:35:32 +01:00
ZwF d8a48bc0af Merge branch '0.2.0b' into main 2026-02-13 10:14:28 -04:00
Keybored d7e1b480dc Merge branch 'maziggy:0.2.0b' into 0.2.0b 2026-02-13 15:09:42 +01:00
Matteo Parenti 6c36fe9ebe Add filament_id tracking for R nozzle 2026-02-13 15:08:47 +01:00
maziggy 2d989bc6e8 Unified 3MF-based filament tracking and notification usage variables (#336)
3MF slicer estimates are now the primary tracking source for ALL spools
(BL and non-BL), with AMS remain% delta as fallback. Per-layer G-code
analysis provides accurate partial usage for failed/cancelled prints.

Fix wrong-spool tracking bug: 3MF slot_id was mapped directly to AMS
tray position, but the printer remaps slicer slots at print time. Now
uses queue ams_mapping for queue prints and tray_now from printer state
for single-filament non-queue prints.

Add filament_grams, filament_details, and progress template variables
to print_complete, print_failed, and print_stopped notification events.
Webhook payloads include per-slot filament breakdown. Per-slot data
stored in archive extra_data during 3MF parsing.
2026-02-13 14:48:50 +01:00
maziggy cf91531aa2 Add next-available printer indicator and fix bulk archive delete race condition (#354)
Status summary bar on the Printers page now shows availability count
("X available") and a "Next available" indicator with printer name,
progress bar, percentage, and remaining time for the printer finishing
soonest. Always visible when printers are printing; hidden otherwise.

Fix race condition in bulk archive deletion where files were removed
from disk before the database commit. Concurrent SQLite writes could
cause a lock timeout, rolling back the DB delete while files were
already gone — leaving orphaned records with broken thumbnails. Now
deletes the DB record first and only removes files after a successful
commit.
2026-02-13 13:06:22 +01:00
maziggy cffe7e62bc Fix maintenance tasks showing wrong rod type for printer models (#351)
H2/A1 series have linear rails, not carbon rods. X1/P1/P2S have carbon
rods, not linear rails. Split rod-specific maintenance into model-aware
pairs: "Lubricate/Clean Carbon Rods" for X1/P1/P2S and "Lubricate/Clean
Linear Rails" for A1/H2. Added rod type classification to printer_models
and startup cleanup for stale/duplicate system maintenance types.
2026-02-13 12:23:34 +01:00
maziggy f9b47282a1 Nozzle-aware AMS mapping for dual-nozzle printers, BL spool detection fix, AMS startup fix, SQLite WAL (#318)
Dual-nozzle H2D/H2D Pro: filament matching now respects nozzle assignments
from the 3MF file. Each AMS unit feeds a specific nozzle (L/R), and the
scheduler/frontend constrain matching to only trays on the correct nozzle.
Falls back to unfiltered matching when no trays exist on the target nozzle.
L/R badges shown in the filament mapping UI. Translated in en/de/ja/it.

Fix AMS slot config overwritten on startup: on_ams_change unconditionally
unlinked BL spool assignments on every MQTT pushall, then re-assigned them
sending ams_filament_setting without setting_id — clearing the printer's
filament preset. Now compares spool RFID identifiers before unlinking.

Fix BL spool detection false positives: removed tray_info_idx from detection
logic in both backend is_bambu_lab_spool() and frontend isBambuLabSpool().
Third-party spools using Bambu generic presets had GF-prefixed tray_info_idx
values, causing misidentification. Now uses only tray_uuid and tag_uid.

SQLite WAL mode with 5s busy timeout reduces "database is locked" errors.
2026-02-13 11:48:32 +01:00
MartinNYHC f054ad7836 Merge branch '0.2.0b' into main 2026-02-13 09:04:51 +01:00
maziggy ee2af79f4a Add confirmation modal to skip objects (#346)
Prevent accidentally skipping the wrong object during a print by showing
a warning confirmation dialog with the object name and an irreversible
action warning. Uses the existing ConfirmModal component with warning
variant. Translations added for all 4 locales (en, de, ja, it).
2026-02-13 08:46:15 +01:00
MartinNYHC d3f2ad0b8d Merge branch '0.2.0b' into main 2026-02-13 08:16:52 +01:00
MartinNYHC bd2f6c4133 Merge pull request #350 from sbcrumb/feature/discord-image-embeds
Add camera image embeds to Discord notifications
2026-02-13 08:16:04 +01:00
MartinNYHC 7fd1218205 Merge branch '0.2.0b' into feature/discord-image-embeds 2026-02-13 08:12:21 +01:00
MartinNYHC ac9bbc354a Merge pull request #348 from sbcrumb/fix/duplicate-error-notifications
Fix duplicate HMS error notifications from race condition
2026-02-13 08:11:28 +01:00
MartinNYHC c5246e60fc Merge branch '0.2.0b' into fix/duplicate-error-notifications 2026-02-13 08:07:44 +01:00
MartinNYHC 179a9de521 Merge pull request #328 from jeffsf/fixes/327
Shut down MQTT relay and smart plug services explicitly
2026-02-13 08:06:35 +01:00
MartinNYHC 7c36283665 Merge branch '0.2.0b' into fixes/327 2026-02-13 08:01:52 +01:00
maziggy e3f3c90c3d Sync 2026-02-13 07:53:14 +01:00
MartinNYHC 2af5289736 Merge branch '0.2.0b' into fixes/327 2026-02-13 06:42:50 +01:00
DevZwF ce4c56fe86 adding french 2026-02-12 23:31:10 -05:00
DevZwF 2e727803fa First pass to add french 2026-02-12 23:27:18 -05:00
Jeff Kletsky c45568bc7e Shut down MQTT relay and smart plug services explicitly
Existing code did not allow the MQTT relay to be shut down gracefully.

Moved _client.loop_stop() after _client.disconnect() call to allow
Paho to be notified to disconnect and shut down without reconnecting.

Added _client._disconnection_event to help prevent a race condition where
a disconnection is requested but the loop is immediately stopped.
Modify _client.disconnect() to take a timeout parameter (default: 0).
Wait in that routine for the disconnection event with the given timeout.

Apply same logic to MQTTSmartPlugService and add to shutdown sequence.

Shutdown the MQTT relay last in lifespan() with a hard-coded 2 sec timeout.

The disconnect timeout is also available to printer MQTT clients.
It is left to the default of 0 at this time. If later enabled,
it should be a configuration parameters, especially for large farms.

Fixes: #327

Signed-off-by: Jeff Kletsky <git-commits@allycomm.com>
2026-02-12 10:25:05 -08:00
maziggy a6f6df2e34 Sync fixes 2026-02-12 18:23:55 +01:00
SBCrumb a942fb5474 Add camera image embeds to Discord notifications
Attach printer camera snapshots to Discord webhook notifications using
multipart form-data with embed image references. Images are included
for print start, complete, progress milestones, and error events.
When no image is available, notifications send as text-only as before.
2026-02-12 12:02:47 -05:00
MartinNYHC 16de29c374 Merge pull request #349 from maziggy/feature/inventory
Feature/inventory
2026-02-12 16:40:43 +01:00
MartinNYHC 44df253c67 Merge branch '0.2.0b' into feature/inventory 2026-02-12 16:38:03 +01:00
MartinNYHC ab1b510f94 Merge pull request #347 from maziggy/maziggy-patch-3
Add requirement for spool without RFID tag
2026-02-12 16:31:57 +01:00
MartinNYHC 469a13519a Add requirement for spool without RFID tag
Added requirement for at least one spool without RFID tag.
2026-02-12 16:31:41 +01:00
MartinNYHC c0dad33517 Merge pull request #345 from maziggy/maziggy-patch-2
Update test case number format in issue reporting
2026-02-12 16:23:07 +01:00
MartinNYHC 1e96ea36f3 Update test case number format in issue reporting 2026-02-12 16:22:43 +01:00
maziggy a1f9ac1376 Added BETA_TEST_PLAN.md 2026-02-12 16:18:36 +01:00
maziggy 620ba5ff2a Added docker-publish-beta.sh 2026-02-12 16:01:05 +01:00
maziggy 1366076b31 Added docker-publish-beta.sh 2026-02-12 16:00:41 +01:00
maziggy e6e62f2a68 Add spool inventory: AMS slot assignment, usage tracking, and remaining weight editing
Built-in spool inventory with AMS slot assignment for non-BL spools,
automatic filament usage tracking via 3MF estimates, and remaining
weight editing in the spool form.

Inventory features:
- AMS slot assignment: assign/unassign manual spools to AMS tray slots
- Filter out Bambu Lab spools (RFID-managed) from assignment modal
- Filter out already-assigned spools (one spool per slot)
- Auto-unlink manual assignments when a BL spool is inserted
- Hide assign/unassign UI on BL-occupied slots
- Case-insensitive fingerprint matching for auto-unlink logic

Usage tracking:
- 3MF-based filament consumption tracking for non-BL spools
- Extract per-filament used_g from archived 3MF slice_info
- Map 3MF slot_id to AMS (ams_id, tray_id) positions
- Scale estimates by print progress for failed/aborted prints
- Skip BL spools (tracked via AMS remain% delta, Path 1)
- Prevent double-counting with handled_trays set

Other:
- Add remaining weight field to spool edit form
- Fix hardcoded "Empty" string in AssignSpoolModal (now i18n)
- Add backend unit tests for usage_tracker (11 tests)
- Add frontend tests for AssignSpoolModal filters (5 tests)
- Update CHANGELOG, README, wiki docs, and website
2026-02-12 15:42:27 +01:00
SBCrumb 107947495d Fix duplicate HMS error notifications from race condition
Move _notified_hms_errors tracking update before the async notification
send to prevent concurrent status callbacks from both seeing the same
errors as new. This mirrors the existing milestone tracking pattern
which correctly updates before the await.
2026-02-12 09:12:50 -05:00
maziggy b423283ec3 Fix queued jobs incorrectly skipped after duplicate execution detection (#341)
When the same file was queued multiple times from the archive, all jobs
after the first were automatically skipped with "already printed X hours
ago". The scheduler's 4-hour safety check compared the shared archive's
completed_at timestamp, incorrectly treating legitimate repeat prints as
phantom reprints from crash recovery. This also affected single queue
items created from recently completed archives.

Remove the check entirely — the crash scenario it guarded against is
already prevented by committing item.status="printing" before sending
the print command.
2026-02-12 12:04:41 +01:00
maziggy 1f0931e00c Sync 2026-02-12 11:54:50 +01:00
maziggy aa87e5598b Add clear plate confirmation between queued prints
The print scheduler previously treated FINISH/FAILED as idle states
and would auto-start the next queued print before the user cleared
the build plate. Now requires explicit user confirmation via a
"Clear Plate & Start Next" button on the printer card. Uses an
in-memory plate-cleared flag — no MQTT command needed since the
scheduler's start_print overrides the printer state.
2026-02-12 08:45:05 +01:00
maziggy 1b5683b3a3 Add "Open in new tab" toggle for external sidebar links (#338)
External links behind reverse proxies (Traefik, nginx) block iframe
embedding via X-Frame-Options/CSP headers. Add a per-link boolean
toggle so users can choose between iframe (default) and new-tab
behavior. Keyboard shortcuts also respect the setting.
2026-02-12 07:51:55 +01:00
maziggy 38a1d6f5e9 Fix Telegram bold title broken by underscores in message body (#332)
Underscores in job names or error codes caused parse_mode to be
disabled entirely, rendering *bold* markers as literal asterisks.
Now escapes underscores in the body with \_ so Markdown stays enabled.
2026-02-12 07:28:54 +01:00
maziggy 5787c61f34 Fix printer card cover image not updating between prints
The cover image URL was always /printers/{id}/cover regardless of the
active print, so the browser served its cached image. Now appends the
print name as a cache-busting query parameter and resets load state
when the print changes.
2026-02-12 07:25:22 +01:00
maziggy 13de96127e Fix file downloads showing generic filenames for special characters (#334)
Content-Disposition parser now handles RFC 5987 percent-encoded filenames
(filename*=utf-8''...) used by FastAPI for non-ASCII characters. Applied
to all 7 download endpoints.

Closes #334
2026-02-12 07:19:03 +01:00