greghesp / ha-bambulab

A Home Assistant Integration for Bambu Lab Printers
696 stars 58 forks source link

[Bug] Broken after 2.0.20 #518

Closed 00svd00 closed 2 months ago

00svd00 commented 2 months ago

Describe the bug

After update to 2.0.20 rtsl stream doen't work

To Reproduce

Install update

Expected Behaviour

Camera is working

What device are you using?

X1C

Diagnostic Output

Unexpected exception importing platform custom_components.bambu_lab.camera
Traceback (most recent call last):
  File "/opt/homeassistant/lib/python3.11/site-packages/homeassistant/loader.py", line 1025, in _load_platform
    cache[full_name] = self._import_platform(platform_name)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homeassistant/lib/python3.11/site-packages/homeassistant/loader.py", line 1058, in _import_platform
    return importlib.import_module(f"{self.pkg_path}.{platform_name}")
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1206, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1178, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1149, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 936, in exec_module
  File "<frozen importlib._bootstrap_external>", line 1074, in get_code
  File "<frozen importlib._bootstrap_external>", line 1004, in source_to_code
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "/home/homeassistant/.homeassistant/custom_components/bambu_lab/camera.py", line 85
    LOGGER.debug(f"Adjusted RTSP URL: {url.replace(self._access_code, "**REDACTED**")}")
                                                                       ^^
SyntaxError: f-string: unmatched '('

Log Extracts

No response

Other Information

No response

AdrianGarside commented 2 months ago

Sorry about that. Fixed in this drop: https://github.com/greghesp/ha-bambulab/releases/tag/v2.0.21