Skip to content

fix: parse -dirty/-unknown suffix in firmware identifiers - #19

Merged
MrKevinWeiss merged 1 commit into
masterfrom
fix/firmware-info
Aug 26, 2026
Merged

MrKevinWeiss merged 1 commit into
masterfrom
fix/firmware-info

Conversation

@MrKevinWeiss

@MrKevinWeiss MrKevinWeiss commented Aug 24, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

FirmwareID rejected version strings where the git describe suffix is followed by -dirty or -unknown, e.g. a locally built firmware reporting:

app-nrf91-origin+0.14.0-rc.1-89-g04cac05-dirty+hw4.lonly TZ3 (Aug 24 2026 16:06:29)

This broke flashing of dirty firmware builds (seen with lob-cord).

Fix

Allow optional -dirty/-unknown suffixes after the git describe part in both identifier regexes. FirmwareVersion already parsed these and sets the dirty/unknown flags correctly.

Tests

  • Regression test with the exact id string extracted from the app-nrf91-origin+0.14.0-rc.1-89-g04cac05+hw4.lonly~full.hex binary
  • Origin-style ids with -dirty and -dirty-unknown after the commit hash
  • Standard-style id with -dirty
  • tox -e lint and full tox pass (65 tests)

Also ignores the Lobaro variant name lonly in codespell.

Co-authored-by: Copilot [email protected]

MrKevinWeiss added a commit that referenced this pull request Aug 26, 2026
PR #19 regex fix lets FirmwareID parse -dirty/-unknown after the git
describe suffix. Add regression tests using the real id string found in
the app-nrf91-origin 0.14.0-rc.1-89-g04cac05 hex plus dirty variants.
Ignore Lobaro variant name 'lonly' in codespell.

Co-authored-by: Copilot <[email protected]>
FirmwareID regex rejected version strings where the git describe suffix
is followed by -dirty or -unknown, e.g. a locally built
'0.14.0-rc.1-89-g04cac05-dirty'. Allow the suffixes after the describe
part so FirmwareVersion can flag them. Add regression tests including
the real id string from the app-nrf91-origin 0.14.0-rc.1-89-g04cac05
hex. Ignore Lobaro variant name 'lonly' in codespell.

Co-authored-by: Copilot <[email protected]>
@MrKevinWeiss MrKevinWeiss changed the title wip: issue with flashing dirty firmware lob-cord fix: parse -dirty/-unknown suffix in firmware identifiers Aug 26, 2026
@MrKevinWeiss
MrKevinWeiss merged commit 9282336 into master Aug 26, 2026
6 checks passed
@MrKevinWeiss
MrKevinWeiss deleted the fix/firmware-info branch August 26, 2026 11:11
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