ha-bambulab icon indicating copy to clipboard operation
ha-bambulab copied to clipboard

[Bug] Cover image not showing in home assistant

Open trwy7 opened this issue 1 year ago • 47 comments
trafficstars

Describe the bug

When I click on the cover image, I get a "500: Internal Server Error"

To Reproduce

  1. Setup printer with Bambu cloud
  2. Input printer IP address

Expected Behaviour

I expected an preview of what was printing

What device are you using?

A1

Diagnostic Output

Github wont let me upload a file here.

{
  "home_assistant": {
    "installation_type": "Home Assistant OS",
    "version": "2023.12.4",
    "dev": false,
    "hassio": true,
    "virtualenv": false,
    "python_version": "3.11.6",
    "docker": true,
    "arch": "aarch64",
    "timezone": "America/Denver",
    "os_name": "Linux",
    "os_version": "6.1.58-haos-raspi",
    "supervisor": "2023.12.0",
    "host_os": "Home Assistant OS 11.2",
    "docker_version": "24.0.7",
    "chassis": "embedded",
    "run_as_root": true
  },
  "custom_components": {
    "bambu_lab": {
      "version": "2.0.3",
      "requirements": []
    },
    "tesla_custom": {
      "version": "3.19.4",
      "requirements": [
        "teslajsonpy==3.9.8"
      ]
    },
    "hacs": {
      "version": "1.33.0",
      "requirements": [
        "aiogithubapi>=22.10.1"
      ]
    },
    "avanza_stock": {
      "version": "1.4.0",
      "requirements": [
        "pyavanza==0.6.0"
      ]
    }
  },
  "integration_manifest": {
    "domain": "bambu_lab",
    "name": "Bambu Lab",
    "codeowners": [
      "@greghesp",
      "@AdrianGarside"
    ],
    "config_flow": true,
    "dependencies": [
      "device_automation",
      "mqtt",
      "ffmpeg"
    ],
    "documentation": "https://github.com/greghesp/ha-bambulab",
    "iot_class": "local_push",
    "issue_tracker": "https://github.com/greghesp/ha-bambulab/issues",
    "ssdp": [
      {
        "st": "urn:bambulab-com:device:3dprinter:1"
      }
    ],
    "version": "2.0.3",
    "is_built_in": false
  },
  "data": {
    "config_entry": {
      "entry_id": "9e9a177268042c4f74190e36c48054cf",
      "version": 2,
      "domain": "bambu_lab",
      "title": "**REDACTED**",
      "data": {
        "device_type": "A1",
        "serial": "**REDACTED**"
      },
      "options": {
        "region": "NorthAmerica",
        "email": "**REDACTED**",
        "username": "**REDACTED**",
        "name": "3DP-039-391",
        "host": "10.0.0.16",
        "local_mqtt": true,
        "auth_token": "**REDACTED**",
        "access_code": "**REDACTED**"
      },
      "pref_disable_new_entities": false,
      "pref_disable_polling": false,
      "source": "user",
      "unique_id": null,
      "disabled_by": null
    },
    "push_all": {
      "upload": {
        "status": "idle",
        "progress": 0,
        "message": ""
      },
      "nozzle_temper": 220.03125,
      "nozzle_target_temper": 220,
      "bed_temper": 65.03125,
      "bed_target_temper": 65,
      "chamber_temper": 5,
      "mc_print_stage": "2",
      "heatbreak_fan_speed": "10",
      "cooling_fan_speed": "14",
      "big_fan1_speed": "14",
      "big_fan2_speed": "14",
      "mc_percent": 39,
      "mc_remaining_time": 97,
      "ams_status": 768,
      "ams_rfid_status": 2,
      "hw_switch_state": 1,
      "spd_mag": 124,
      "spd_lvl": 3,
      "print_error": 0,
      "lifecycle": "product",
      "wifi_signal": "-56dBm",
      "gcode_state": "RUNNING",
      "gcode_file_prepare_percent": "100",
      "queue_number": 0,
      "queue_total": 0,
      "queue_est": 0,
      "queue_sts": 0,
      "project_id": "37974737",
      "profile_id": "37571471",
      "task_id": "73926202",
      "subtask_id": "73926203",
      "subtask_name": "Marble Run 003",
      "gcode_file": "Marble Run 003.3mf",
      "stg": [
        2,
        13,
        24,
        4,
        3,
        14,
        13
      ],
      "stg_cur": 0,
      "print_type": "cloud",
      "home_flag": 3687863,
      "mc_print_line_number": "99689",
      "mc_print_sub_stage": 1,
      "sdcard": true,
      "force_upgrade": false,
      "mess_production_state": "active",
      "layer_num": 381,
      "total_layer_num": 1189,
      "s_obj": [],
      "fan_gear": 255,
      "upgrade_state": {
        "sequence_id": 0,
        "progress": "",
        "status": "",
        "consistency_request": false,
        "dis_state": 0,
        "err_code": 0,
        "force_upgrade": false,
        "message": "0%, 0B/s",
        "module": "",
        "new_version_state": 2,
        "cur_state_code": 1,
        "new_ver_list": []
      },
      "hms": [],
      "online": {
        "ahb": false,
        "rfid": false,
        "version": 924850508
      },
      "ams": {
        "ams": [
          {
            "id": "0",
            "humidity": "5",
            "temp": "0.0",
            "tray": [
              {
                "id": "0",
                "remain": 100,
                "k": 0.019999999552965164,
                "n": 1,
                "tag_uid": "0000000000000000",
                "tray_id_name": "",
                "tray_info_idx": "GFL03",
                "tray_type": "PLA",
                "tray_sub_brands": "",
                "tray_color": "FFFFFFFF",
                "tray_weight": "0",
                "tray_diameter": "0.00",
                "tray_temp": "0",
                "tray_time": "0",
                "bed_temp_type": "0",
                "bed_temp": "0",
                "nozzle_temp_max": "240",
                "nozzle_temp_min": "190",
                "xcam_info": "000000000000000000000000",
                "tray_uuid": "00000000000000000000000000000000"
              },
              {
                "id": "1",
                "remain": 100,
                "k": 0.019999999552965164,
                "n": 1,
                "tag_uid": "0000000000000000",
                "tray_id_name": "",
                "tray_info_idx": "GFL03",
                "tray_type": "PLA",
                "tray_sub_brands": "",
                "tray_color": "DD4646FF",
                "tray_weight": "0",
                "tray_diameter": "0.00",
                "tray_temp": "0",
                "tray_time": "0",
                "bed_temp_type": "0",
                "bed_temp": "0",
                "nozzle_temp_max": "240",
                "nozzle_temp_min": "190",
                "xcam_info": "000000000000000000000000",
                "tray_uuid": "00000000000000000000000000000000"
              },
              {
                "id": "2",
                "remain": 100,
                "k": 0.019999999552965164,
                "n": 1,
                "tag_uid": "0000000000000000",
                "tray_id_name": "",
                "tray_info_idx": "GFL03",
                "tray_type": "PLA",
                "tray_sub_brands": "",
                "tray_color": "0D3ADAFF",
                "tray_weight": "0",
                "tray_diameter": "0.00",
                "tray_temp": "0",
                "tray_time": "0",
                "bed_temp_type": "0",
                "bed_temp": "0",
                "nozzle_temp_max": "240",
                "nozzle_temp_min": "190",
                "xcam_info": "000000000000000000000000",
                "tray_uuid": "00000000000000000000000000000000"
              },
              {
                "id": "3",
                "remain": 100,
                "k": 0.019999999552965164,
                "n": 1,
                "tag_uid": "0000000000000000",
                "tray_id_name": "",
                "tray_info_idx": "GFL03",
                "tray_type": "PLA",
                "tray_sub_brands": "",
                "tray_color": "AFF31EFF",
                "tray_weight": "0",
                "tray_diameter": "0.00",
                "tray_temp": "0",
                "tray_time": "0",
                "bed_temp_type": "0",
                "bed_temp": "0",
                "nozzle_temp_max": "240",
                "nozzle_temp_min": "190",
                "xcam_info": "000000000000000000000000",
                "tray_uuid": "00000000000000000000000000000000"
              }
            ]
          }
        ],
        "ams_exist_bits": "1",
        "tray_exist_bits": "f",
        "tray_is_bbl_bits": "f",
        "tray_tar": "0",
        "tray_now": "0",
        "tray_pre": "0",
        "tray_read_done_bits": "f",
        "tray_reading_bits": "0",
        "version": 15,
        "insert_flag": true,
        "power_on_flag": false
      },
      "ipcam": {
        "ipcam_dev": "1",
        "ipcam_record": "enable",
        "timelapse": "disable",
        "resolution": "1536x1080",
        "mode_bits": 3
      },
      "vt_tray": {
        "id": "254",
        "tag_uid": "0000000000000000",
        "tray_id_name": "",
        "tray_info_idx": "",
        "tray_type": "",
        "tray_sub_brands": "",
        "tray_color": "00000000",
        "tray_weight": "0",
        "tray_diameter": "0.00",
        "tray_temp": "0",
        "tray_time": "0",
        "bed_temp_type": "0",
        "bed_temp": "0",
        "nozzle_temp_max": "0",
        "nozzle_temp_min": "0",
        "xcam_info": "000000000000000000000000",
        "tray_uuid": "00000000000000000000000000000000",
        "remain": 0,
        "k": 0.019999999552965164,
        "n": 1
      },
      "lights_report": [
        {
          "node": "chamber_light",
          "mode": "on"
        }
      ],
      "command": "push_status",
      "msg": 0,
      "sequence_id": "12623"
    },
    "get_version": {
      "command": "get_version",
      "sequence_id": "0",
      "module": [
        {
          "name": "ota",
          "project_name": "N2S",
          "sw_ver": "01.01.01.00",
          "hw_ver": "OTA",
          "sn": "**REDACTED**"
        },
        {
          "name": "esp32",
          "project_name": "N2S",
          "sw_ver": "01.07.22.30",
          "hw_ver": "AP05",
          "sn": "**REDACTED**"
        },
        {
          "name": "mc",
          "project_name": "N2S",
          "sw_ver": "00.00.20.63",
          "loader_ver": "00.00.00.32",
          "hw_ver": "MC02",
          "sn": "**REDACTED**"
        },
        {
          "name": "th",
          "project_name": "N2S",
          "sw_ver": "00.00.06.74",
          "loader_ver": "00.00.00.26",
          "hw_ver": "TH01",
          "sn": "**REDACTED**"
        },
        {
          "name": "ams_f1/0",
          "project_name": "",
          "sw_ver": "00.00.07.89",
          "loader_ver": "00.00.00.00",
          "ota_ver": "00.00.00.00",
          "hw_ver": "AMS_F102",
          "sn": "**REDACTED**"
        }
      ],
      "result": "success",
      "reason": ""
    }
  }
}

Log Extracts

No response

Other Information

Continuation of #368 (https://github.com/greghesp/ha-bambulab/issues/368#issuecomment-1872256399)

trwy7 avatar Dec 30 '23 22:12 trwy7

image Forgot to add my screenshot

trwy7 avatar Dec 30 '23 22:12 trwy7

I’m going to need debug logs to have any hope of working out why it’s not working for you. What version of the integration are you running? And what version of home assistant?

AdrianGarside avatar Dec 31 '23 04:12 AdrianGarside

Version: 2.0.3 Home assistant version: 2023.12.4 Home assistant frontend version: 20231208.2

trwy7 avatar Jan 01 '24 20:01 trwy7

I’m having the same issue.

Version: 2.0.5 Home Assistant Core 2024.1.1

Can you provide debug logs of a repro please.

AdrianGarside avatar Jan 06 '24 05:01 AdrianGarside

Can you provide debug logs of a repro please.

All i get is 2024-01-06 16:04:55.949 DEBUG (Thread-26) [custom_components.bambu_lab.pybambu] JPEG RECEIVED: A1 2024-01-06 16:04:55.950 DEBUG (Thread-26) [custom_components.bambu_lab] Manually updated bambu_lab data 2024-01-06 16:04:55.962 DEBUG (Thread-26) [custom_components.bambu_lab.pybambu] JPEG RECEIVED: A1 2024-01-06 16:04:55.963 DEBUG (Thread-26) [custom_components.bambu_lab] Manually updated bambu_lab data 2024-01-06 16:04:56.973 DEBUG (Thread-26) [custom_components.bambu_lab.pybambu] JPEG RECEIVED: A1 2024-01-06 16:04:56.974 DEBUG (Thread-26) [custom_components.bambu_lab] Manually updated bambu_lab data 2024-01-06 16:04:56.989 DEBUG (Thread-26) [custom_components.bambu_lab.pybambu] JPEG RECEIVED: A1 2024-01-06 16:04:56.989 DEBUG (Thread-26) [custom_components.bambu_lab] Manually updated bambu_lab data 2024-01-06 16:04:57.721 DEBUG (Thread-17 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Received data from: A1 2024-01-06 16:04:57.722 DEBUG (Thread-17 (mqtt_listen_thread)) [custom_components.bambu_lab] Manually updated bambu_lab data. It keeps repeating in my logs, and no other issues show. (except warnings from other integrations)

trwy7 avatar Jan 06 '24 23:01 trwy7

The cover image is only downloaded at print start or integration start. There will be logs about looking up the task information.

AdrianGarside avatar Jan 07 '24 01:01 AdrianGarside

Actually your log snippet looks incomplete. The only activity showing is the camera image. You should be seeing lines like this:

2024-01-07 14:42:16.294 DEBUG (Thread-4 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Received data from: P1P Sometimes (but not always) paired with additional 'Manually updated bambu_lab' entries when any of the data changed.

AdrianGarside avatar Jan 07 '24 22:01 AdrianGarside

Actually your log snippet looks incomplete. The only activity showing is the camera image. You should be seeing lines like this:

2024-01-07 14:42:16.294 DEBUG (Thread-4 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Received data from: P1P Sometimes (but not always) paired with additional 'Manually updated bambu_lab' entries when any of the data changed.

Yep I did not notice that, it happens about every 10 manually updated data lines.

This log is taken straight after an integration restart 2024-01-11 17:23:18.846 DEBUG (Thread-23) [custom_components.bambu_lab] Manually updated bambu_lab data 2024-01-11 17:23:19.399 DEBUG (MainThread) [custom_components.bambu_lab] async_unload_entry 2024-01-11 17:23:19.399 DEBUG (MainThread) [custom_components.bambu_lab] async_unload_entry: (<Platform.BINARY_SENSOR: 'binary_sensor'>, <Platform.BUTTON: 'button'>, <Platform.CAMERA: 'camera'>, <Platform.FAN: 'fan'>, <Platform.IMAGE: 'image'>, <Platform.LIGHT: 'light'>, <Platform.SELECT: 'select'>, <Platform.SENSOR: 'sensor'>, <Platform.SWITCH: 'switch'>) 2024-01-11 17:23:19.436 DEBUG (MainThread) [custom_components.bambu_lab.pybambu] Disconnect: Client Disconnecting 2024-01-11 17:23:19.437 WARNING (MainThread) [custom_components.bambu_lab.pybambu] On Disconnect: Disconnected from Broker: 0 2024-01-11 17:23:19.438 DEBUG (MainThread) [custom_components.bambu_lab] Manually updated bambu_lab data 2024-01-11 17:23:19.440 INFO (Thread-22) [custom_components.bambu_lab.pybambu] Watchdog thread exited. 2024-01-11 17:23:19.858 INFO (Thread-23) [custom_components.bambu_lab.pybambu] A1: Chamber image thread exited. 2024-01-11 17:23:19.860 DEBUG (MainThread) [custom_components.bambu_lab] Async Setup Unload Done 2024-01-11 17:23:19.861 DEBUG (MainThread) [custom_components.bambu_lab] async_setup_entry Start 2024-01-11 17:23:19.862 DEBUG (MainThread) [custom_components.bambu_lab] ConfigEntry.Id: c961f228781819a169d2bbaa499fdc9f 2024-01-11 17:23:19.862 DEBUG (MainThread) [custom_components.bambu_lab] HA POLL: MQTT connected: False 2024-01-11 17:23:19.863 DEBUG (MainThread) [custom_components.bambu_lab] Finished fetching bambu_lab data in 0.000 seconds (success: True) 2024-01-11 17:23:19.866 WARNING (Thread-17 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] On Disconnect: Disconnected from Broker: 0 2024-01-11 17:23:19.870 DEBUG (Thread-17 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Ended listen loop. 2024-01-11 17:23:19.870 INFO (Thread-17 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] MQTT listener thread exited. 2024-01-11 17:23:19.901 DEBUG (MainThread) [custom_components.bambu_lab] BUTTON::async_setup_entry 2024-01-11 17:23:19.901 DEBUG (MainThread) [custom_components.bambu_lab] CAMERA::async_setup_entry 2024-01-11 17:23:19.901 DEBUG (MainThread) [custom_components.bambu_lab] FAN::async_setup_entry 2024-01-11 17:23:19.901 DEBUG (MainThread) [custom_components.bambu_lab] FAN::async_setup_entry DONE 2024-01-11 17:23:19.902 DEBUG (MainThread) [custom_components.bambu_lab] IMAGE::async_setup_entry 2024-01-11 17:23:19.902 DEBUG (MainThread) [custom_components.bambu_lab] SELECT::async_setup_entry 2024-01-11 17:23:19.903 DEBUG (MainThread) [custom_components.bambu_lab] SWITCH::async_setup_entry 2024-01-11 17:23:19.963 DEBUG (MainThread) [custom_components.bambu_lab] async_setup_entry Complete 2024-01-11 17:23:19.963 DEBUG (MainThread) [custom_components.bambu_lab] Starting MQTT 2024-01-11 17:23:20.032 DEBUG (MainThread) [custom_components.bambu_lab.pybambu] Starting MQTT listener thread 2024-01-11 17:23:20.033 INFO (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] MQTT listener thread started. 2024-01-11 17:23:20.033 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Connect: Attempting Connection to 10.0.0.16 2024-01-11 17:23:20.899 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Starting listen loop 2024-01-11 17:23:20.908 INFO (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] On Connect: Connected to Broker 2024-01-11 17:23:20.908 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Now subscribing... 2024-01-11 17:23:20.908 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Subscribing: device/SERIALNUMBER/report 2024-01-11 17:23:20.909 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] On Connect: Getting version info 2024-01-11 17:23:20.909 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Sent {'info': {'sequence_id': '0', 'command': 'get_version'}} to topic device/SERIALNUMBER/request 2024-01-11 17:23:20.910 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] On Connect: Request push all 2024-01-11 17:23:20.910 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Sent {'pushing': {'sequence_id': '0', 'command': 'pushall'}} to topic device/SERIALNUMBER/request 2024-01-11 17:23:20.910 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Starting watchdog thread 2024-01-11 17:23:20.912 INFO (Thread-63) [custom_components.bambu_lab.pybambu] Watchdog thread started. 2024-01-11 17:23:20.913 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Starting Chamber Image thread 2024-01-11 17:23:20.915 DEBUG (Thread-64) [custom_components.bambu_lab.pybambu] {self._client._device.info.device_type}: Chamber image thread started. 2024-01-11 17:23:20.935 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Received data from: A1 2024-01-11 17:23:20.935 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab] Manually updated bambu_lab data 2024-01-11 17:23:20.939 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Got Version Data 2024-01-11 17:23:20.939 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Device is A1 2024-01-11 17:23:20.940 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab] '01.01.01.00' 'AP05' 2024-01-11 17:23:20.940 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Device is A1 2024-01-11 17:23:20.940 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab] Initialize AMS 1 2024-01-11 17:23:21.360 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Received data from: A1 2024-01-11 17:23:21.361 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Getting task list from Bambu Cloud for Printer: SERIALNUMBER 2024-01-11 17:23:21.410 DEBUG (MainThread) [custom_components.bambu_lab] _reinitialize_sensors START 2024-01-11 17:23:21.410 DEBUG (MainThread) [custom_components.bambu_lab] async_forward_entry_unload 2024-01-11 17:23:21.431 DEBUG (MainThread) [custom_components.bambu_lab] async_forward_entry_setup 2024-01-11 17:23:21.505 DEBUG (MainThread) [custom_components.bambu_lab] _reinitialize_sensors DONE 2024-01-11 17:23:21.595 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab] Manually updated bambu_lab data 2024-01-11 17:23:21.757 DEBUG (Thread-64) [custom_components.bambu_lab.pybambu] A1: SOCKET STATUS: 0 2024-01-11 17:23:23.367 DEBUG (Thread-62 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Received data from: A1 2024-01-11 17:23:23.766 DEBUG (Thread-64) [custom_components.bambu_lab] Manually updated bambu_lab data

trwy7 avatar Jan 12 '24 00:01 trwy7

Well that shows normal startup. The camera image thread successfully started and connected successfully to the printer. It should have been receiving the image data from that point onwards and sending it to HA.

Edit: Ignore this - got my wires crossed between the printer chamber image and the cover image. The log above doesn't go far enough to cover the querying of bambu cloud for last print data.

AdrianGarside avatar Jan 12 '24 05:01 AdrianGarside

If you right click the missing image, and copy the image URL, what does it show?

greghesp avatar Jan 13 '24 15:01 greghesp

If you right click the missing image, and copy the image URL, what does it show?

https://DOMAIN.com/api/image_proxy/image.PRINTER_cover_image?token=TOKEN&state=2024-01-13T10:43:48.115168 The actual link shows a 500: internal server error, without the reverse proxy, I get ERR_SSL_PROTOCOL_ERROR

trwy7 avatar Jan 14 '24 18:01 trwy7

How is your HA setup configured to be accessed? I get http://<local IP>:8123/api/image_proxy/... and I proxy myself so my external access is all to the :8123 port. Are you connecting from out of network in your entire usage?

AdrianGarside avatar Jan 14 '24 19:01 AdrianGarside

How is your HA setup configured to be accessed? I get http://<local IP>:8123/api/image_proxy/... Are you connecting from out of network in your entire usage?

Yes, except on mobile (seems counter intuitive, probably is). It goes Domain > nginx > home assistant

trwy7 avatar Jan 14 '24 19:01 trwy7

Unfortunately I think that's the problem. That indirection is somehow breaking access to the image. Is your chamber image broken too in the same way? I assume it must be given they're generated in-memory the same way for handoff to HA. In the integration we just hand the image bytes off to HA after that it's out of our control.

AdrianGarside avatar Jan 14 '24 19:01 AdrianGarside

Unfortunately I think that's the problem. That indirection is somehow breaking access to the image. Is your chamber image broken too in the same way? I assume it must be given they're generated in-memory the same way for handoff to HA. In the integration we just hand the image bytes off to HA after that it's out of our control.

Nope, only cover image.

trwy7 avatar Jan 14 '24 21:01 trwy7

Well then, scratch that theory. Since the images are handle identically that means the download itself is presumably failing. There should be a log entries like this in the debug logs:

2024-01-14 22:37:08.829 DEBUG (Thread-4 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Getting latest task from Bambu Cloud for Printer: SERIAL
2024-01-14 22:37:08.829 DEBUG (Thread-4 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Getting task list from Bambu Cloud for Printer: SERIAL
2024-01-14 22:37:08.953 DEBUG (Thread-4 (mqtt_listen_thread)) [custom_components.bambu_lab.pybambu] Downloading cover image: https://bbl-prod-us-model.s3.dualstack.us-west-1.amazonaws.com/private/US8c71ea8cf18b02/41407571/3mf/Metadata/plate_1.png?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAXY6FH2ERKOLIVPHB%2F20240115%2Fus-west-1%2Fs3%2Faws4_request&X-Amz-Date=20240115T063708Z&X-Amz-Expires=60&X-Amz-SignedHeaders=host&X-Amz-Signature=1c5b7790af664212a62c232ac3cae76653c848375653c91fb4b6d791bfa292f2

If that's not present then the integration is not even attempting to do the download in which case something about your bambu login credentials isn't working.

AdrianGarside avatar Jan 14 '24 23:01 AdrianGarside

Do you have correct print weight / length / bed type sensor values?

AdrianGarside avatar Jan 14 '24 23:01 AdrianGarside

Do you have correct print weight / length / bed type sensor values?

Nope, all at 0

trwy7 avatar Jan 17 '24 01:01 trwy7

The connection to Bambu cloud is failing then. What Happens if you try to reconfigure the printer? It’s supposed to test the connection there and re request Bambu credentials if it cannot connect but that’s a little difficult to test.

AdrianGarside avatar Jan 17 '24 03:01 AdrianGarside

Please reopen with more information.

AdrianGarside avatar Feb 02 '24 22:02 AdrianGarside

I now have a P1S due to the recall, so I was forced to reconfigure. Nothing has changed

trwy7 avatar Feb 07 '24 23:02 trwy7

I cannot reopen

trwy7 avatar Feb 07 '24 23:02 trwy7

Seems like this is specific to your account then. Need you to check debug logs for any relevant errors/logging as you're starting a cloud print.

AdrianGarside avatar Feb 08 '24 07:02 AdrianGarside

All i am seeing there is 2024-01-27 11:45:23.403 ERROR (Thread-14) [custom_components.bambu_lab.pybambu] A1: A Chamber Image thread outer exception occurred:

2024-01-27 11:45:20.331 ERROR (Thread-14) [custom_components.bambu_lab.pybambu] A1: Exception. Type: <class 'OSError'> Args: [Errno 113] Host is unreachable:

trwy7 avatar Feb 09 '24 23:02 trwy7

That would be the error if the IP address is wrong but local mqtt connection would also fail then. I see it still thinks your device is an A1 though - is that logging because your A1 is still configured in the integration?

AdrianGarside avatar Feb 10 '24 00:02 AdrianGarside

That would be the error if the IP address is wrong but local mqtt connection would also fail then. I see it still thinks your device is an A1 though - is that logging because your A1 is still configured in the integration?

I see that, however it was already removed.

trwy7 avatar Feb 12 '24 17:02 trwy7

I would consider removing the integration completely and re-adding it. Something has gotten messed up in it's configuration at this point.

AdrianGarside avatar Feb 13 '24 04:02 AdrianGarside

Stale issue message

github-actions[bot] avatar Apr 13 '24 08:04 github-actions[bot]

@AdrianGarside Have the same issue. Picture was shown successfully for quite a long time but stop working after HA upgrade to 2024.4.

Spirituss avatar Apr 22 '24 06:04 Spirituss