Skip to content

webui: group the device firmware update dialog by device type and version - #292

Merged
jens-maus merged 1 commit into
mainfrom
jens-maus/webui-improved-firmware-dialog
Nov 1, 2026
Merged

jens-maus merged 1 commit into
mainfrom
jens-maus/webui-improved-firmware-dialog

Conversation

@jens-maus

@jens-maus jens-maus commented Nov 1, 2026 •

Copy link
Copy Markdown
Member

Original OpenCCU rootfs patch: 0183
Original filename: 0183-WebUI-ImprovedFirmwareupdateDialog.patch
Original patch: https://github.com/OpenCCU/OpenCCU/blob/4d1d123a6/buildroot-external/package/openccu-base/rootfs-patches/0183-WebUI-ImprovedFirmwareupdateDialog.patch
Fixes before migration:

This applies the patch as fixed by OpenCCU/OpenCCU#4625. The device firmware update dialog of the start page groups the updatable devices by device type and current firmware version instead of listing every device:

  • Start page (src/webui/www_source/webui/js/pages/startpage/startpage.js): StartPage.cmpVersion() compares dotted versions numerically. showAllDeviceFirmware()/setDeviceVersion() collect the devices per type and current version in DeviceUpdateList (count, addresses, whether the firmware still has to be downloaded or is already uploaded). showAvailableDeviceFirmware() renders one row per group with the device count, the hidden serial numbers, the current version (bold and orange when it is newer than the recommended one) and the recommended version, which links to the download area or shows the "already uploaded" hint. A short instruction below the table links to "Device firmware".
  • Serial numbers (src/webui/www_source/webui/js/dialog/statusdisplaydialogacousticepaper.js, where the patch placed it in the generated webui.js): the global toggleSerialNumberDisplay() shows or hides the serial number column, together with its <col>, when the device count is clicked.
  • Translations (src/webui/www/webui/js/lang/{de,en}/translate.lang.extension.js): new and renamed column headers and the instruction texts; the German file now ends with a newline.

All files keep their line endings and encodings (CRLF for startpage.js). The generated webui.js and all other staged files are byte-identical to the OpenCCU patch. The three comment lines of cmpVersion keep the trailing spaces of the original patch for that reason.

The keyboard operability of the device count cell stays open in OpenCCU/OpenCCU#4361, together with the other mouse-only WebUI controls collected there.

Validation

  • OpenCCU scripts/base-patch-migration.py validate with the canonical Buildroot 2026.08.1 git4 archive of this change (416f83b1, sha256 f542ce84a943008b747e0525c5af215e954c0e6bad2414141a206ef033f4fcbc, based on the current OpenCCU pin 641809a7) and --skip-patch 0183, on the OpenCCU state of fix(webui): keep the serial number column of the firmware dialog in the table OpenCCU#4625: PASS (the other 15 rootfs patches apply with zero fuzz; the security tests of the validation passed).
  • compare with a validation of the same OpenCCU state with all 16 patches: IDENTICAL (all 4667 manifest entries, transition candidate-skip of 0183).
  • Not tested on a running CCU.

The OpenCCU cleanup PR (removal of 0183, pin and archive hash) will follow after this PR is merged.


Generated by Claude Code

Summary by CodeRabbit

  • New Features
    • Firmware updates are grouped by device type and current firmware version, with device counts shown for each group.
    • Expand a group to view its device serial numbers.
    • Firmware versions are compared by their numeric components, so recommendations reflect version order accurately.
    • The update dialog includes download and upload instructions.
  • Improvements
    • Updated English and German labels clarify device type, serial numbers, current version, and recommended version.

@coderabbitai

coderabbitai Bot commented Nov 1, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review.

Recent review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: c08ac587-e31c-4daa-8455-70efac33da7b
Commits

Reviewing files that changed from the base of the PR and between 641809a and 416f83b.

Files selected for processing: 4
  • src/webui/www/webui/js/lang/de/translate.lang.extension.js
  • src/webui/www/webui/js/lang/en/translate.lang.extension.js
  • src/webui/www_source/webui/js/dialog/statusdisplaydialogacousticepaper.js
  • src/webui/www_source/webui/js/pages/startpage/startpage.js

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

Walkthrough

Firmware update entries are now grouped by device type and current firmware. The dialog compares version components numerically, displays grouped counts and serial-number details, and includes updated instructions and labels in English and German.

Changes: Firmware update dialog

Layer / File(s) Summary
Version comparison and device grouping
src/webui/www_source/webui/js/pages/startpage/startpage.js
Version components are compared numerically, with missing components treated as zero. Eligible devices are grouped by type and current firmware, with counts, addresses, and firmware upload status tracked.
Grouped update dialog
src/webui/www_source/webui/js/pages/startpage/startpage.js, src/webui/www_source/webui/js/dialog/statusdisplaydialogacousticepaper.js, src/webui/www/webui/js/lang/en/translate.lang.extension.js, src/webui/www/webui/js/lang/de/translate.lang.extension.js
The dialog displays sorted grouped rows, device counts, and serial-number details. It highlights newer current versions and selects the download or already-uploaded alert based on group status. The serial-number column can be hidden or shown. English and German labels and instructions are updated.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Change: Feature

Sequence Diagram(s)

sequenceDiagram
  participant StartPage
  participant DeviceUpdateList
  participant fwUpdates
  StartPage->>DeviceUpdateList: Initialize update list before device-list fetch
  StartPage->>DeviceUpdateList: Store grouped device and firmware data
  StartPage->>fwUpdates: Render grouped rows and update instructions
Loading

Possibly related PRs

Suggested reviewers: cn-eq3

Merge Risk: Minimal · up to 416f8

Firmware updates are grouped by device type and version. No merge-blocking issue was established.

Pre-merge checks: Passed 4 · Failed 1

Failed Failed checks: 1 warning

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat… Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 4 passed
Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title clearly and concisely describes the main change: grouping the device firmware update dialog by device type and firmware version.
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 1 functions across 4 files.

Resolution

Write docstrings for the functions missing them to satisfy the coverage threshold.

Finishing Touches
Generate docstrings
  • Commit to this branch
  • Create a new PR
Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@jens-maus
jens-maus merged commit 01e4007 into main Nov 1, 2026
6 checks passed
@jens-maus
jens-maus deleted the jens-maus/webui-improved-firmware-dialog branch November 1, 2026 19:28

Copy link
Copy Markdown
Member Author

OpenCCU cleanup PR: OpenCCU/OpenCCU#4628 (removes rootfs patch 0183 and pins OpenCCU-Base to the merge commit 01e40077).


Generated by Claude Code

jens-maus added a commit to OpenCCU/OpenCCU that referenced this pull request Nov 1, 2026
This removes OpenCCU rootfs patch 0183-WebUI-ImprovedFirmwareupdateDialog.patch, now that OpenCCU/OpenCCU-Base#292 is merged.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant