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

PyPy's resolvedPyPyVersion has a trailing newline #609

Closed
3 of 5 tasks
kurtmckee opened this issue Feb 11, 2023 · 8 comments · Fixed by #610
Closed
3 of 5 tasks

PyPy's resolvedPyPyVersion has a trailing newline #609

kurtmckee opened this issue Feb 11, 2023 · 8 comments · Fixed by #610
Labels
bug Something isn't working

Comments

@kurtmckee
Copy link
Contributor

kurtmckee commented Feb 11, 2023

Description:
While working on #606 I discovered that PyPy's resolvedPyPyVersion contains a trailing newline, which causes the pythonVersion (passed to cacheDependencies) to look like 7.3.11\n-3.9.16.

Action version:
I'm running code against the main branch. The bug only exists on Ubuntu and macOS runners. The Windows runner does not have the trailing newline.

Platform:

  • Ubuntu
  • macOS
  • Windows

Runner type:

  • Hosted
  • Self-hosted

Tools version:
PyPy 7.3.11 with Python 3.9.16

Repro steps:
You can see the issue in the output of the "Installed versions" output group. I've created a repo to demonstrate the issue with a simple workflow:

https://github.com/kurtmckee/demonstrate-pypy-newlines/actions/runs/4151696169/jobs/7182162044

Expected behavior:
I expect that the resolvedPyPyVersion variable will not have a trailing newline.

Actual behavior:
resolvedPyPyVersion has a trailing newline, and this can be seen in the "Installed versions" output group's text:

On Ubuntu and macOS:

  Successfully set up PyPy 7.3.11
   with Python (3.9.16)

On Windows:

  Successfully set up PyPy 7.3.11 with Python (3.9.16)
@kurtmckee kurtmckee added bug Something isn't working needs triage labels Feb 11, 2023
@kurtmckee
Copy link
Contributor Author

I'm working to resolve this now and will open a PR shortly.

kurtmckee added a commit to kurtmckee/pr-setup-python that referenced this issue Feb 11, 2023
@e-korolevskii
Copy link
Contributor

Hello @kurtmckee! Thank you for reporting this!
We will investigate the issue and get back to you as soon as we have updates.

@kurtmckee
Copy link
Contributor Author

Thanks @e-korolevskii! I think I've fixed this in PR #610. Please take a look when you have an opportunity. 😀

@dmitry-shibanov
Copy link
Contributor

Hello @kurtmckee. We've merged your pull request. Could you please try to use setup-python as actions/setup-python@main to confirm that everything works as expected? Later we'll prepare the release and update the major tag.

@kurtmckee
Copy link
Contributor Author

Will do! I'll report back shortly.

@kurtmckee
Copy link
Contributor Author

I've tested this against actions/setup-python@main and the bug is indeed fixed. Thank you all very much for the quick review and merge!

Before

[link]

  Successfully set up PyPy 7.3.11
   with Python (3.9.16)

After

[link]

  Successfully set up PyPy 7.3.11 with Python (3.9.16)

@dmitry-shibanov
Copy link
Contributor

Hello @kurtmckee. Thank you for your response. For now I'll reopen the until the new version is released.

@kurtmckee
Copy link
Contributor Author

The fix was released in v4.6.0. Closing.

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

Successfully merging a pull request may close this issue.

3 participants