Skip to content

Fix false duplicate warning for multiple --log targets - #257

Open
aavdberg wants to merge 1 commit into
LukasGrebe:mainfrom
aavdberg:patch-1
Open

Fix false duplicate warning for multiple --log targets#257
aavdberg wants to merge 1 commit into
LukasGrebe:mainfrom
aavdberg:patch-1

Conversation

@aavdberg

Copy link
Copy Markdown

Problem

The duplicate flag detection logic only considers the flag name
before the = character.

As a result, configurations like:

commandline_options:
  - "--log=all:notice"
  - "--log=bus:notice"

Fix duplicate flag detection for --log options

The addon previously treated all --log=<component>:<level>
arguments as duplicates because duplicate detection only
considered the flag name before '='.

This change uses the log component as part of the duplicate
key, allowing configurations such as:

  --log=all:notice
  --log=bus:notice

without generating false duplicate warnings.

Duplicate detection still works for actual duplicates of the
same log target, e.g.:

  --log=bus:notice
  --log=bus:debug
``
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