Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python version: factor mapping causes side-effect on Tox v4 #178

Open
bittner opened this issue May 22, 2023 · 2 comments
Open

Python version: factor mapping causes side-effect on Tox v4 #178

bittner opened this issue May 22, 2023 · 2 comments
Labels
bug Something isn't working enhancement New feature or request

Comments

@bittner
Copy link

bittner commented May 22, 2023

Describe the bug
tox-gh-actions uses a colon : in the version = factor mapping, which causes Tox to interpret the left part (version) as "additional environments". See tox-dev/tox#3014 for details.

To Reproduce

  1. Configure a [gh-actions] section with default mappings in tox.ini
  2. Run tox list locally
  3. Inspect the output (versions are listed as "additional environments")

Expected behavior
The tox-gh-actions configuration should not confuse Tox. It should not be possible that keys of the python mapping are interpreted as environments. This may be achieved by replacing : by =.

Additional context
A Tox maintainer suggests to use tox-gh instead of tox-gh-actions in tox-dev/tox#3014. Unfortunately, that plugin only supports Python > 3.6 -- and I have projects that try to support older versions of Python.

I'd be interested in tox-gh-actions fixing the issue and keep supporting older Pythons.

@ymyzk
Copy link
Owner

ymyzk commented Jul 6, 2023

Thanks for reporting the issue.

The use of : is imported from tox-dev/tox-travis (it's a plugin under tox-dev 😅) https://tox-travis.readthedocs.io/en/stable/envlist.html when tox-gh-action is created initially. As changing the syntax will cause build failures, we need to think about how to fix this issue carefully.

By updating our parser, we may be able to both : and = and migrate to = eventually in the future. I'll find time to think about this problem.

@ymyzk ymyzk added bug Something isn't working enhancement New feature or request labels Jul 6, 2023
@bittner
Copy link
Author

bittner commented Jul 6, 2023

By updating our parser, we may be able to both : and = and migrate to = eventually in the future.

That sounds promising. Lets proceed with that. 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants