-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
[Bug] 7zip causes decompress permission errors #4647
Comments
I just upgraded 7zip to 21.06, but gcloud installs fine for me.
|
reproduced with PS C:\Users\HUMOR> scoop list 7zip
Installed apps matching '7zip':
7zip 21.06 [main]
7zip-zstd v21.03-v1.5.0-R2 [versions]
PS C:\Users\HUMOR> scoop reset 7zip
Resetting 7zip (21.06).
Linking ~\scoop\apps\7zip\current => ~\scoop\apps\7zip\21.06
Creating shim for '7z'.
Creating shortcut for 7-Zip (7zFM.exe)
Persisting Codecs
Persisting Formats
PS C:\Users\HUMOR> scoop install gcloud
WARN Purging previous failed installation of gcloud.
Uninstalling 'gcloud' ().
'gcloud' was uninstalled.
Installing 'gcloud' (365.0.1) [64bit]
Loading google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip from cache
Checking hash of google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip ... ok.
Extracting google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip ... ERROR Exit code was 2!
Failed to extract files from C:\Users\HUMOR\scoop\apps\gcloud\365.0.1\google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip.
Log file:
~\scoop\apps\gcloud\365.0.1\7zip.log
Please try again or create a new issue by using the following link and paste your console output:
https://github.com/ScoopInstaller/Extras/issues/new?title=gcloud%40365.0.1%3a+decompress+error
PS C:\Users\HUMOR> cat ~\scoop\apps\gcloud\365.0.1\7zip.log
7-Zip 21.06 (x64) : Copyright (c) 1999-2021 Igor Pavlov : 2021-11-24
Scanning the drive for archives:
1 file, 146151332 bytes (140 MiB)
Extracting archive: C:\Users\HUMOR\scoop\apps\gcloud\365.0.1\google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip
--
Path = C:\Users\HUMOR\scoop\apps\gcloud\365.0.1\google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip
Type = zip
Physical Size = 146151332
Sub items Errors: 4
Archives with Errors: 1
Sub items Errors: 4
PS C:\Users\HUMOR> scoop reset 7zip-zstd
Resetting 7zip-zstd (v21.03-v1.5.0-R2).
Linking ~\scoop\apps\7zip-zstd\current => ~\scoop\apps\7zip-zstd\v21.03-v1.5.0-R2
Creating shim for '7z'.
WARN Overwriting shim to 7z.exe installed from 7zip
Creating shim for '7zG'.
Creating shortcut for 7-Zip (7zFM.exe)
PS C:\Users\HUMOR> scoop install gcloud
WARN Purging previous failed installation of gcloud.
Uninstalling 'gcloud' ().
'gcloud' was uninstalled.
Installing 'gcloud' (365.0.1) [64bit]
Loading google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip from cache
Checking hash of google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip ... ok.
Extracting google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip ... ERROR Exit code was 2!
Failed to extract files from C:\Users\HUMOR\scoop\apps\gcloud\365.0.1\google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip.
Log file:
~\scoop\apps\gcloud\365.0.1\7zip.log
Please try again or create a new issue by using the following link and paste your console output:
https://github.com/ScoopInstaller/Extras/issues/new?title=gcloud%40365.0.1%3a+decompress+error
PS C:\Users\HUMOR> cat ~\scoop\apps\gcloud\365.0.1\7zip.log
7-Zip 21.06 (x64) : Copyright (c) 1999-2021 Igor Pavlov : 2021-11-24
Scanning the drive for archives:
1 file, 146151332 bytes (140 MiB)
Extracting archive: C:\Users\HUMOR\scoop\apps\gcloud\365.0.1\google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip
--
Path = C:\Users\HUMOR\scoop\apps\gcloud\365.0.1\google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip
Type = zip
Physical Size = 146151332
Sub items Errors: 4
Archives with Errors: 1
Sub items Errors: 4
### SCOOP'S BUG, TEMPORARY UNINSTALL `main/7zip`
PS C:\Users\HUMOR> scoop uninstall 7zip
Uninstalling '7zip' (21.06).
Removing shim for '7z'.
Removing shortcut ~\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Scoop Apps\7-Zip.lnk
Unlinking ~\scoop\apps\7zip\current
'7zip' was uninstalled.
PS C:\Users\HUMOR> scoop reset 7zip-zstd
Resetting 7zip-zstd (v21.03-v1.5.0-R2).
Linking ~\scoop\apps\7zip-zstd\current => ~\scoop\apps\7zip-zstd\v21.03-v1.5.0-R2
Creating shim for '7z'.
Creating shim for '7zG'.
Creating shortcut for 7-Zip (7zFM.exe)
PS C:\Users\HUMOR> scoop install gcloud
WARN Purging previous failed installation of gcloud.
Uninstalling 'gcloud' ().
'gcloud' was uninstalled.
Installing 'gcloud' (365.0.1) [64bit]
Loading google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip from cache
Checking hash of google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip ... ok.
Extracting google-cloud-sdk-365.0.1-windows-x86_64-bundled-python.zip ...
### STUCK HERE MORE THAN 10 MINS (FOREVERY?) |
Also seeing this bug using the latest versions of 7zip and gcloud available through scoop. |
Had the same issue for gcloud-366.
Thanks! |
I'm having the same problem with gcloud version 366.
|
From @peterleif in ScoopInstaller/Main#3042:
|
From @zoof in ScoopInstaller/Extras#7310:
|
As I wrote in ScoopInstaller/Main#3042 I suspect that 7zip recently changed the handling of symbolic link (and other kinds of special files?) and it causes issues on some Windows environments (where symbolic link creation by a normal user is prohibited). |
Downgrading 7zip to 19.00 solved ScoopInstaller/Main#3042. |
I think 7zip team needs to fix this issue, but simple workaround here is to show message to suggest changing windows settings like this (I've not tested this article)? |
Seems like it's the only workaround for now.
The instructions here are for Win 7 and 8. For Windows 10, 11, you can just enable Developer Mode in the Settings. |
I test geany and git-filter-repo and they can be both extracted in PS5 and PS7... 'cos that, I've no idea what cause this bug. And also, after checking 7-zip's history.txt, there isn't something that related to Windows system permission. |
@rashil2000 Thanks for the information. I switched to developer mode and now I can install git-filter-repo using the latest 7-zip. @niheaven Maybe you are running windows with the developer mode enabled. |
I can't switch to developer mode because... Rights. (and that's the reason why I use scoop to install things locally to my account) Has an issue been raised on 7zip? |
7zip was updated to 22.00. Does this issue still occur? |
Yes, the problem is not solved. Situation is the same. |
If this helps anyone it wouldn't let me to downgrade to 19.00 ( |
I'm fighting this issue on PowerShell 5.1 with old 7zip v22.x setting . |
e.g. Using scoop See: ScoopInstaller/Scoop#4647: Fix: newren#249
7zip-beta still gives me error, also I cant downgrade to 19.00:
You cannot call a method on a null-valued expression.
|
arm64 is the clue here for why you can't downgrade. 7zip-19 dates from before arm64 versions of windows, so that's why you can't downgrade; developer mode is the other accepted work-around, your mileage may vary with that, but I always turn on developer mode now. |
This comment was marked as abuse.
This comment was marked as abuse.
Just wanted to add some info. 7-Zip 19.00 actually succeeds because it's not creating a symbolic link for the two files affected upon extraction. Instead it just creates a plain text file whose contents is the symlink target. Thus technically, newer versions of 7-Zip are actually doing the right thing. The problem really is that Windows doesn't allow non-admins to create symbolic links unless Developer Mode is enabled. The only solution I can suggest is that the Scoop package is updated to skip extraction of the two symlinks.
The symlinks really are not needed and appear to be there moreso for backwards compatibility for those using the old commands. Cheers |
use 7zip19.00-helper due to ScoopInstaller/Scoop#4647
Steps to reproduce
I think this is related to ScoopInstaller/Extras#7310
If you install/update 7zip to 21.06 then gcloud doesn't install properly (365.0.1 or 365.0.0). It fails to unzip the file properly.
The 7zip.log file contains
Workaround
Downgrading to 7zip 19.00 appears to work with gcloud 365.0.1 and 365.0.0; so I'm not sure which of the packages is actually showing up the exception.
I chose 7zip 19.00 as this was the last version I had installed (not for any other reason) before updating to 21.06
This sequence of steps works :
EDIT: Enabling developer mode is also viable as a workaround, if you have that choice : #4647 (comment) / #4647 (comment)
It also appears to be the case that scoop may now install the
7zip19.00-helper
in some situations to mitigate this problem (it depends on the application manifest in question).The text was updated successfully, but these errors were encountered: