Skip to content

Conversation

tpoliaw
Copy link
Contributor

@tpoliaw tpoliaw commented May 28, 2025

In 3.13 the behaviour of the locals builtin changed so that
modifications no longer had any affect in certain situations. This meant
the plot CLI subcommand would raise NameError for single letter axis
names as used in the cli tests.

Passing the locals as a new mapping allows the same code to work with
both the new and old locals behaviour.

Fixes #163

Instructions to reviewer on how to test:

  1. Run tests under Python 3.13 (eg uv run --extra dev --python 3.13 pytest)
  2. Check tests pass

Checks for reviewer

  • Would the PR title make sense to a user on a set of release notes

@tpoliaw tpoliaw requested a review from coretl May 29, 2025 14:33
Copy link
Contributor

@coretl coretl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code changes look fine, will the CI be fixed elsewhere?

@tpoliaw
Copy link
Contributor Author

tpoliaw commented Jun 16, 2025

Code changes look fine, will the CI be fixed elsewhere?

Should already have been fixed by #166

In 3.13 the behaviour of the locals builtin changed so that
modifications no longer had any affect in certain situations. This meant
the plot CLI subcommand would raise NameError for single letter axis
names as used in the cli tests.

Passing the locals as a new mapping allows the same code to work with
both the new and old locals behaviour.
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.

CLI doesn't work in Python 3.13 due to locals change
2 participants