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

FIX: Extract zip win #827

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

SMoraisAnsys
Copy link

@SMoraisAnsys SMoraisAnsys commented Feb 29, 2024

Description:

Changes consist in reordering extract utils to first attemps ExtractToDirectory and then Expand-Archive. For some reason the download CPython release was not correctly handled by Expand-Archive. This could be happening if the zip file was compressed using an unsupported compression method (e.g. through zip with Unix/Linux).

Related issue: #819

Check list:

  • Mark if documentation changes are required.
  • Mark if tests were added or updated to cover the changes.

@SMoraisAnsys SMoraisAnsys requested a review from a team as a code owner February 29, 2024 23:03
@SMoraisAnsys
Copy link
Author

@priyagupta108 I took the liberty to take a look at #819 and I think this changes should correct the issue. I tested it on my repo and it works fine (didn't do intensive testing though).

Copy link

@RobPasMue RobPasMue left a comment

Choose a reason for hiding this comment

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

This will solve so many issues! Windows self-hosted runners could no longer use "v5" if the Python version requested was not available in the cache or in the system already. We can finally use the action as is without having to stick to "v4" or implement workarounds!

Related to actions#819

Changes consist in reordering extract utils to first attemps
ExtractToDirectory and then Expand-Archive. For some
reason the download CPython release was not correctly
handled by Expand-Archive. This could be happening if the
zip file was compressed using an unsupported
compression method (e.g. through `zip` with Unix/linux).
@SMoraisAnsys SMoraisAnsys force-pushed the fix/windows_extract_cpython_release branch from 606bed9 to 4de2ef7 Compare March 30, 2024 10:59
@SMoraisAnsys
Copy link
Author

I took the liberty to reproduce the error (fixed by this PR) on a github runner. The associated branch (https://github.com/SMoraisAnsys/setup-python/tree/test/no-pwshpath) consists in removing a part of the code of function extractZipWin(file, dest) in order to ensure that the runner uses the failing part of the code.

PR that can be used to oversee the changes : SMoraisAnsys#1
Failing CI log : https://github.com/SMoraisAnsys/setup-python/actions/runs/8491166206/job/23262896827?pr=1

@RobPasMue
Copy link

@actions/setup-actions-team could we get this reviewed and merged soon?

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.

None yet

2 participants