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

Installation fails on Windows 11 #118

Open
dnys1 opened this issue Dec 31, 2023 · 1 comment · May be fixed by #119
Open

Installation fails on Windows 11 #118

dnys1 opened this issue Dec 31, 2023 · 1 comment · May be fixed by #119

Comments

@dnys1
Copy link

dnys1 commented Dec 31, 2023

When installing on Windows 11 (ARM64), I get the following error:

Installing the windows-arm64 Dart SDK version 3.3.0-174.3.beta from the beta (release) channel.
https://storage.googleapis.com/dart-archive/channels/beta/release/3.3.0-174.3.beta/sdk/dartsdk-windows-arm64-release.zip ...
C:\WINDOWS\System32\WindowsPowerShell\v1.0\powershell.exe -NoLogo -Sta -NoProfile -NonInteractive -ExecutionPolicy Unrestricted -Command "$ErrorActionPreference = 'Stop' ; try { Add-Type -AssemblyName System.IO.Compression.FileSystem } catch { } ; if ((Get-Command -Name Expand-Archive -Module Microsoft.PowerShell.Archive -ErrorAction Ignore)) { Expand-Archive -LiteralPath 'C:\actions-runner\_work\_temp\c314cd0b-3c6[8](https://github.com/celest-dev/cloud/actions/runs/7372205470/job/20060311893?pr=166#step:3:9)-48f7-a571-b2ee052b271d' -DestinationPath 'C:\actions-runner\_work\_temp\28[9](https://github.com/celest-dev/cloud/actions/runs/7372205470/job/20060311893?pr=166#step:3:10)b3aa8-b730-4025-a328-c1359a33f75d' -Force } else {[System.IO.Compression.ZipFile]::ExtractToDirectory('C:\actions-runner\_work\_temp\c314cd0b-3c68-48f7-a571-b2ee052b271d', 'C:\actions-runner\_work\_temp\289b3aa8-b730-4025-a328-c1359a33f75d', $true) }"
Expand-Archive :  is not a supported archive file format. .zip is the only supported archive file format.
At line:1 char:2[10](https://github.com/celest-dev/cloud/actions/runs/7372205470/job/20060311893?pr=166#step:3:11)
+ ...  Ignore)) { Expand-Archive -LiteralPath 'C:\actions-runner\_work\_tem ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (:String) [Expand-Archive], IOException
    + FullyQualifiedErrorId : NotSupportedArchiveFileExtension,Expand-Archive
 
Error: Error: The process 'C:\WINDOWS\System32\WindowsPowerShell\v1.0\powershell.exe' failed with exit code 1
dnys1 added a commit to dnys1/setup-dart that referenced this issue Dec 31, 2023
Fixes dart-lang#118

Ensures that downloads of the Dart SDK zip file carry the `.zip` extension so that subsequent calls to `Expand-Archive` on Windows succeed.

## Notes

- Uses Dart `3.3.0-16.0.dev`. The current version (`3.3.0-5.0.dev`) is not published so I kept it to the closest published version.
- The diff of `index.mjs` is quite large. I believe this is due to the version of Node I'm using (`20.7.0`). Happy to use a different version to keep the diff small, but wasn't sure which one is currently used.
dnys1 added a commit to dnys1/setup-dart that referenced this issue Dec 31, 2023
Fixes dart-lang#118

Ensures that downloads of the Dart SDK zip file carry the `.zip` extension so that subsequent calls to `Expand-Archive` on Windows succeed.

## Notes

- Uses Dart `3.3.0-16.0.dev`. The current version (`3.3.0-5.0.dev`) is not published so I kept it to the closest published version.
- The diff of `index.mjs` is quite large. I believe this is due to the version of Node I'm using (`20.7.0`). Happy to use a different version to keep the diff small, but wasn't sure which one is currently used.
@dnys1 dnys1 linked a pull request Dec 31, 2023 that will close this issue
1 task
@dnys1
Copy link
Author

dnys1 commented Dec 31, 2023

Seems to be an issue in how @actions/tool-cache determines the destination path:

https://github.com/actions/toolkit/blob/5430c5d84832076372990c7c27f900878ff66dc9/packages/tool-cache/src/tool-cache.ts#L44

I've opened #119 to resolve this. Please let me know if this is better resolved in the tool-cache repo instead.

dnys1 added a commit to dnys1/setup-dart that referenced this issue May 1, 2024
Fixes dart-lang#118

Ensures that downloads of the Dart SDK zip file carry the `.zip` extension so that subsequent calls to `Expand-Archive` on Windows succeed.

## Notes

- The diff of `index.mjs` is quite large. I believe this is due to the version of Node I'm using (`20.7.0`). Happy to use a different version to keep the diff small, but wasn't sure which one is currently used. This could be noted in `package.json` to ensure alignment with external contributions.
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 a pull request may close this issue.

1 participant