Skip to content

Upgrade fails for custom firmware when brand does not match release asset filename prefix #2096

Description

@paulbsmith

Problem

Firmware upgrade fails for a QuinLED Dig2Go because python-wled constructs the firmware filename using the device's reported brand.

The Dig2Go reports:

brand: QuinLED
release: Dig2Go-Audioreactive
repo: intermittech/QuinLED-Firmware

When upgrading from WLED 16.0.0 to 16.0.1, python-wled attempts to download:

QuinLED_16.0.1_Dig2Go-Audioreactive.bin

and returns:

Requested firmware file QuinLED_16.0.1_Dig2Go-Audioreactive.bin does not exist

However, the firmware asset published in the configured QuinLED repository is:

WLED_16.0.1_Dig2Go-Audioreactive.bin

I was able to manually install that firmware successfully.

Cause

The upgrade code appears to construct the filename as:

if self._device.info.release is not None:
    update_file = (
        f"{self._device.info.brand}_{version}"
        f"_{self._device.info.release}.bin{gzip}"
    )

This assumes that the device's brand is also the prefix used for firmware assets.

For the Dig2Go, however, the firmware defines:

WLED_BRAND="QuinLED"
WLED_RELEASE_NAME="Dig2Go-Audioreactive"

while the release asset is prefixed with WLED_, not QuinLED_.

Steps to reproduce

  1. Use a QuinLED Dig2Go running WLED 16.0.0.
  2. Check the configured QuinLED firmware repository and discover WLED 16.0.1.
  3. Attempt an upgrade through python-wled (in my case through Home Assistant's WLED integration).
  4. The upgrade fails because it requests QuinLED_16.0.1_Dig2Go-Audioreactive.bin.
  5. WLED_16.0.1_Dig2Go-Audioreactive.bin exists in the same v16.0.1 release and installs successfully when uploaded manually.

Expected behavior

python-wled should be able to select the firmware asset corresponding to the reported release without assuming that WLED_BRAND is the filename prefix.

One possible approach would be to match against the assets in the GitHub release rather than constructing the complete filename from brand, or otherwise provide/fall back to the appropriate asset naming convention for custom firmware repositories.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions