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-file does not support multiple versions #894

Open
5 tasks done
astro-stan opened this issue Jun 16, 2024 · 2 comments
Open
5 tasks done

python-version-file does not support multiple versions #894

astro-stan opened this issue Jun 16, 2024 · 2 comments
Labels
feature request New feature or request to improve the current logic

Comments

@astro-stan
Copy link

astro-stan commented Jun 16, 2024

Description:
It is possible to specify multiple python versions like so:

- uses: actions/setup-python@v5
  with:
    python-version: |
      3.8
      3.9
      3.10

However, specifying them like so breaks CI:

.python-version:

3.8
3.9
3.10
- uses: actions/setup-python@v5
   with:
     python-version-file: '.python-version'

Action version:
5

Platform:

  • Ubuntu
  • macOS
  • Windows

Runner type:

  • Hosted
  • Self-hosted

Tools version:

Repro steps:
See description

Expected behavior:
Multiple python versions can be read from .python-version

Actual behavior:
Multiple python versions cannot be read from .python-version

@astro-stan astro-stan added bug Something isn't working needs triage labels Jun 16, 2024
@aparnajyothi-y
Copy link
Contributor

Hello @sdimovv, Thank you for creating this issue and we will look into it :)

@aparnajyothi-y aparnajyothi-y self-assigned this Jul 5, 2024
@aparnajyothi-y
Copy link
Contributor

Hello @sdimovv, Thank you once again for creating this issue and as per the current implementation, the actions/setup-python action does not support reading multiple Python versions from a .python-version file. Instead, we should specify multiple versions directly in the yaml configuration under the python-version parameter like below as per this documentation.

  • uses: actions/setup-python@v5
    with:
    python-version: |
    3.8
    3.9
    3.10

    Adding support to list multiple versions from a python-version-file that is expecting from this issue can be implemented as a feature request.

@aparnajyothi-y aparnajyothi-y removed their assignment Jul 11, 2024
@aparnajyothi-y aparnajyothi-y added feature request New feature or request to improve the current logic and removed bug Something isn't working labels Jul 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request New feature or request to improve the current logic
Projects
None yet
Development

No branches or pull requests

2 participants