Skip to content

fix(log): handle invalid test/series IDs without uncaught ValueError - #1072

Open
SAY-5 wants to merge 1 commit into
hpc:stablefrom
SAY-5:fix/log-bad-test-id
Open

fix(log): handle invalid test/series IDs without uncaught ValueError#1072
SAY-5 wants to merge 1 commit into
hpc:stablefrom
SAY-5:fix/log-bad-test-id

Conversation

@SAY-5

@SAY-5 SAY-5 commented May 12, 2026

Copy link
Copy Markdown

Code review checklist:

  • Code is generally sensical and well commented
  • Variable/function names all telegraph their purpose and contents
  • Functions/classes have useful doc strings
  • Function arguments are typed
  • Added/modified unit tests to cover changes.
  • New features have documentation added to the docs.
  • New features and backwards compatibility breaks are noted in the RELEASE.md

Fixes #1064.

When pav log <subcmd> <id> is passed an id that is neither a valid TestID nor a valid SeriesID, LogCommand.run falls through to SeriesID(args.id), whose constructor raises an uncaught ValueError and crashes the CLI.

This guards the conversion with SeriesID.is_valid_id and prints a readable error before returning 1, matching how the other "load failed" paths in this command already behave. Adds a regression test.

@hwikle-lanl
hwikle-lanl self-requested a review June 15, 2026 19:28
@hwikle-lanl

Copy link
Copy Markdown
Collaborator

Hi @SAY-5,

Thanks for contributing! Can you reopen this against the stable branch? That's where we're targeting all of our bug fixes.

Thanks!

@hwikle-lanl hwikle-lanl self-assigned this Aug 6, 2026
@hwikle-lanl
hwikle-lanl changed the base branch from develop to stable August 6, 2026 21:49
@SAY-5
SAY-5 force-pushed the fix/log-bad-test-id branch from c5c7901 to a1e5b0e Compare August 16, 2026 09:52
@SAY-5

SAY-5 commented Aug 16, 2026

Copy link
Copy Markdown
Author

Retargeted this to stable and rebased the branch onto it, so the PR is now just the single log.py guard plus its test.

Signed-off-by: Sai Asish Y <say.apm35@gmail.com>
@SAY-5
SAY-5 force-pushed the fix/log-bad-test-id branch from a1e5b0e to 31ea420 Compare August 23, 2026 06:57
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.

Uncaught ValueError when passing bad test IDs to pav log

2 participants