Files
bambuddy/backend
maziggy c514e1f2af Fix Bambu Lab spool detection and AMS tray data persistence
Issue 1: Spool detection only checked tray_uuid/tag_uid, missing spools
  that have tray_info_idx (Bambu preset ID like "GFG02") but incomplete
  RFID data.

  Issue 2: Partial MQTT updates from printer could overwrite complete tray
  data, causing loss of tray_sub_brands, tray_id_name, and other fields.

  Backend changes (services/spoolman.py):
  - Add tray_info_idx to AMSTray dataclass
  - Parse tray_info_idx from raw MQTT data
  - Check tray_info_idx first in is_bambu_lab_spool() (GF* prefix)
  - Fall back to tray_uuid then tag_uid for identification
  - Add warning when Bambu spool detected but no unique ID for Spoolman

  Backend changes (api/routes/spoolman.py):
  - Pass tray_info_idx to is_bambu_lab_spool() in both sync endpoints
  - Guard against empty spool_tag when adding to tracking set

  Backend changes (services/bambu_mqtt.py):
  - Implement deep merge at tray level for AMS MQTT updates
  - Preserve existing tray fields unless new update has non-empty value
  - Numeric fields (remain, k, id, cali_idx) always update

  Frontend changes (pages/PrintersPage.tsx):
  - Add isBambuLabSpool() helper with same detection logic as backend
  - Check tray_info_idx (GF*), tray_uuid, and tag_uid
  - Update all 4 vendor detection locations in AMS cards
2026-01-16 06:59:10 +01:00
..
2025-11-28 10:23:59 +01:00