Skip to content

Commit

Permalink
Raise ValueError from assigned variable
Browse files Browse the repository at this point in the history
Co-authored-by: Henry Schreiner <[email protected]>
  • Loading branch information
stefanv and henryiii authored Feb 28, 2024
1 parent 847e11e commit 3fa17ee
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions nox/sessions.py
Original file line number Diff line number Diff line change
Expand Up @@ -380,8 +380,8 @@ def run(
raise ValueError("At least one argument required to run().")

if len(args) == 1 and isinstance(args[0], (list, tuple)):
raise ValueError("First argument to `session.run` is a list. "
"Did you mean to use `session.run(*args)`?")
msg = "First argument to `session.run` is a list. Did you mean to use `session.run(*args)`?"
raise ValueError(msg)

if self._runner.global_config.install_only:
logger.info(f"Skipping {args[0]} run, as --install-only is set.")
Expand Down

0 comments on commit 3fa17ee

Please sign in to comment.