8000 Update bundled 7zip executables to v23.01 · Issue #3285 · chocolatey/choco · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Update bundled 7zip executables to v23.01 #3285
Closed
@msitt

Description

@msitt

Checklist

  • I have verified this is the correct repository for opening this issue.
  • I have verified no other issues exist related to my problem.
  • I have verified this is not an issue for a specific package.
  • I have verified this issue is not security related.
  • I confirm I am using official, and not unofficial, or modified, Chocolatey products.

What You Are Seeing?

I am trying to install a package using Install-ChocolateyZipPackage. The source file is a 7z archive created using 7z v23.01.

Choco will attempt to unpack this file using its own built in version of 7z from C:\ProgramData\chocolatey\tools\7z.exe. As of the latest version of choco v2.2.0, this version of 7z is v21.07. This version of 7z is incapable of unpacking this file, which causes the choco install to fail.

What is Expected?

I would like some way to override the 7z binary which is used for this command. I actually have the latest version of 7z installed on this machine via choco install 7zip.install.

A workaround would be the bump the bundled version of 7z to the latest.

How Did You Get This To Happen?

To reproduce, you must create an archive which is incompatible with the bundled version of 7z. In the case of 7z v23 vs v21, 7z has an improved way of compressing ARM libraries. As an example you can find some binaries in the Microsoft.Data.SqlClient.SNI NuGet package. If you compress these files using v23, you will get a 7z file which will fail to install using choco v2.2.0.

System Details

  • Operating System: Windows Server 2019
  • Windows PowerShell version: 5.1.17763.2803
  • Chocolatey CLI Version: 2.2.0

Installed Packages

Chocolatey v2.2.0
7zip 23.1.0
7zip.install 23.1.0
chocolatey 2.2.0
chocolatey-core.extension 1.3.5.1

Output Log

2023-07-27 20:50:41,541 8404 [DEBUG] - Running Install-ChocolateyZipPackage -packageName 'InternalPackage' -url 'http://XXXXXXXX/InternalPackage.5.0.0.292.7z' -unzipLocation 'E:\InternalPackage\bin' -specificFolder '' 
2023-07-27 20:50:41,588 8404 [DEBUG] - Running Get-ChocolateyWebFile -checksum '' -checksumType '' -checksum64 '' -checksumType64 '' -options 'System.Collections.Hashtable' -getOriginalFileName 'True' -packageName 'InternalPackage' -fileFullPath 'C:\Users\XX\AppData\Local\Temp\chocolatey\InternalPackage\5.0.0.292\InternalPackageInstall.zip' -url 'http://XXXXXXXX/InternalPackage.5.0.0.292.7z' -url64bit '' 
2023-07-27 20:50:41,588 8404 [DEBUG] - Running Get-ProcessorBits -compare '64' 
2023-07-27 20:50:41,603 8404 [DEBUG] - CPU is 64 bit
2023-07-27 20:50:41,619 8404 [DEBUG] - Running Get-WebHeaders -url 'https://XXXXXXXX/InternalPackage.5.0.0.292.7z' -ErrorAction 'Stop' 
2023-07-27 20:50:41,650 8404 [DEBUG] - Setting the UserAgent to 'chocolatey command line'
2023-07-27 20:50:41,650 8404 [DEBUG] - Request Headers:
2023-07-27 20:50:41,666 8404 [DEBUG] -   'Accept':'*/*'
2023-07-27 20:50:41,666 8404 [DEBUG] -   'User-Agent':'chocolatey command line'
2023-07-27 20:50:42,853 8404 [DEBUG] - Url does not have HTTPS available
2023-07-27 20:50:42,869 8404 [DEBUG] - Running Get-WebFileName -url 'http://XXXXXXXX/InternalPackage.5.0.0.292.7z' -defaultName 'InternalPackageInstall.zip' 
2023-07-27 20:50:42,932 8404 [DEBUG] - Using response url to determine file name. 'http://XXXXXXXX/InternalPackage.5.0.0.292.7z'
2023-07-27 20:50:42,947 8404 [DEBUG] - File name determined from url is 'InternalPackage.5.0.0.292.7z'
2023-07-27 20:50:42,947 8404 [DEBUG] - Running Get-WebHeaders -url 'http://XXXXXXXX/InternalPackage.5.0.0.292.7z' -ErrorAction 'Stop' 
2023-07-27 20:50:42,947 8404 [DEBUG] - Setting the UserAgent to 'chocolatey command line'
2023-07-27 20:50:42,947 8404 [DEBUG] - Request Headers:
2023-07-27 20:50:42,963 8404 [DEBUG] -   'Accept':'*/*'
2023-07-27 20:50:42,963 8404 [DEBUG] -   'User-Agent':'chocolatey command line'
2023-07-27 20:50:43,010 8404 [DEBUG] - Response Headers:
2023-07-27 20:50:43,010 8404 [DEBUG] -   'X-Content-Type-Options':'nosniff'
2023-07-27 20:50:43,010 8404 [DEBUG] -   'Content-Security-Policy':'sandbox allow-forms allow-modals allow-popups allow-presentation allow-scripts allow-top-navigation'
2023-07-27 20:50:43,010 8404 [DEBUG] -   'X-XSS-Protection':'1; mode=block'
2023-07-27 20:50:43,010 8404 [DEBUG] -   'Content-Disposition':'inline'
2023-07-27 20:50:43,010 8404 [DEBUG] -   'Content-Length':'5507418'
2023-07-27 20:50:43,010 8404 [DEBUG] -   'Content-Type':'application/x-7z-compressed'
2023-07-27 20:50:43,010 8404 [DEBUG] -   'Date':'Fri, 28 Jul 2023 03:50:43 GMT'
2023-07-27 20:50:43,010 8404 [DEBUG] -   'Last-Modified':'Mon, 24 Jul 2023 14:06:57 GMT'
2023-07-27 20:50:43,010 8404 [DEBUG] -   'Server':'Nexus/3.27.0-03 (OSS)'
2023-07-27 20:50:43,025 8404 [INFO ] - Downloading InternalPackage 
  from 'http://XXXXXXXX/InternalPackage.5.0.0.292.7z'
2023-07-27 20:50:43,025 8404 [DEBUG] - Running Get-WebFile -url 'http://XXXXXXXX/InternalPackage.5.0.0.292.7z' -fileName 'C:\Users\XX\AppData\Local\Temp\chocolatey\InternalPackage\5.0.0.292\InternalPackage.5.0.0.292.7z' -options 'System.Collections.Hashtable' 
2023-07-27 20:50:43,041 8404 [DEBUG] - Setting request timeout to  30000
2023-07-27 20:50:43,041 8404 [DEBUG] - Setting read/write timeout to  2700000
2023-07-27 20:50:43,041 8404 [DEBUG] - Setting the UserAgent to 'chocolatey command line'
2023-07-27 20:50:43,260 8404 [DEBUG] - Downloading http://XXXXXXXX/InternalPackage.5.0.0.292.7z to C:\Users\XX\AppData\Local\Temp\chocolatey\InternalPackage\5.0.0.292\InternalPackage.5.0.0.292.7z
2023-07-27 20:50:43,307 8404 [INFO ] - 
2023-07-27 20:50:43,307 8404 [INFO ] - Download of InternalPackage.5.0.0.292.7z (5.25 MB) completed.
2023-07-27 20:50:46,338 8404 [DEBUG] - No runtime virus checking built into FOSS Chocolatey. Check out Pro/Business - https://chocolatey.org/compare
2023-07-27 20:50:46,338 8404 [DEBUG] - Checking that 'C:\Users\XX\AppData\Local\Temp\chocolatey\InternalPackage\5.0.0.292\InternalPackage.5.0.0.292.7z' is the size we expect it to be.
2023-07-27 20:50:46,338 8404 [DEBUG] - Verifying package provided checksum of '' for 'C:\Users\XX\AppData\Local\Temp\chocolatey\InternalPackage\5.0.0.292\InternalPackage.5.0.0.292.7z'.
2023-07-27 20:50:46,354 8404 [DEBUG] - Running Get-ChecksumValid -file 'C:\Users\XX\AppData\Local\Temp\chocolatey\InternalPackage\5.0.0.292\InternalPackage.5.0.0.292.7z' -checksum '' -checksumType '' -originalUrl 'http://XXXXXXXX/InternalPackage.5.0.0.292.7z' 
2023-07-27 20:50:46,354 8404 [DEBUG] - Empty checksums are allowed due to allowEmptyChecksums feature or option.
2023-07-27 20:50:46,354 8404 [DEBUG] - Running Get-ChocolateyUnzip -fileFullPath 'C:\Users\XX\AppData\Local\Temp\chocolatey\InternalPackage\5.0.0.292\InternalPackage.5.0.0.292.7z' -destination 'E:\InternalPackage\bin' -specificFolder '' -packageName 'InternalPackage' 
2023-07-27 20:50:46,354 8404 [DEBUG] - Running Get-ProcessorBits -compare '32' 
2023-07-27 20:50:46,369 8404 [INFO ] - Extracting C:\Users\XX\AppData\Local\Temp\chocolatey\InternalPackage\5.0.0.292\InternalPackage.5.0.0.292.7z to E:\InternalPackage\bin...
2023-07-27 20:50:46,369 8404 [DEBUG] - 7zip found at 'C:\ProgramData\chocolatey\tools\7z.exe'
2023-07-27 20:50:46,385 8404 [DEBUG] - Executing command ['C:\ProgramData\chocolatey\tools\7z.exe' x -aoa -bd -bb1 -o"E:\InternalPackage\bin" -y "C:\Users\XX\AppData\Local\Temp\chocolatey\InternalPackage\5.0.0.292\InternalPackage.5.0.0.292.7z"]
2023-07-27 20:50:46,947 8404 [INFO ] - VERBOSE: Scanning the drive for archives:
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: Extracting archive: C:\Users\XX\AppData\Local\Temp\chocolatey\InternalPackage\5.0.0.292\InternalPackage.5.0.0.292.7z
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: 
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: 
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: 
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: 1 file, 5507418 bytes (5379 KiB)
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: 7-Zip 18.06 (x86) : Copyright (c) 1999-2018 Igor Pavlov : 2018-12-30
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: --
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: Physical Size = 5507418
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: Path = C:\Users\XX\AppData\Local\Temp\chocolatey\InternalPackage\5.0.0.292\InternalPackage.5.0.0.292.7z
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: Headers Size = 2205
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: Type = 7z
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: Solid = +
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: Blocks = 4
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: Method = 0A LZMA2:24 BCJ ARMT
2023-07-27 20:50:46,963 8404 [INFO ] - VERBOSE: - runtimes
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\browser\lib
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\browser\lib\net6.0
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\browser
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\unix\lib
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: 
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\unix\lib\netcoreapp3.1
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\win
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\unix
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\win\lib
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\win\lib\netcoreapp2.1
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\unix\lib\netcoreapp3.0
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\win\lib\netcoreapp3.0
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\win\lib\net6.0
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\win\lib\netstandard2.0
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\win-arm
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\win\lib\netcoreapp3.1
2023-07-27 20:50:46,979 8404 [INFO ] - VERBOSE: - runtimes\win-arm64
2023-07-27 20:50:46,994 8404 [INFO ] - VERBOSE: - runtimes\win-arm64\native
2023-07-27 20:50:46,994 8404 [INFO ] - VERBOSE: - runtimes\win-arm\native
2023-07-27 20:50:46,994 8404 [INFO ] - VERBOSE: - runtimes\win-x64
2023-07-27 20:50:46,994 8404 [INFO ] - VERBOSE: - runtimes\win-x64\native
2023-07-27 20:50:46,994 8404 [INFO ] - VERBOSE: - runtimes\win-x86
2023-07-27 20:50:46,994 8404 [INFO ] - VERBOSE: - runtimes\win-x86\native
2023-07-27 20:50:46,994 8404 [INFO ] - VERBOSE: T runtimes\win-arm64\native\Microsoft.Data.SqlClient.SNI.dll
2023-07-27 20:50:47,026 8404 [INFO ] - VERBOSE: - runtimes\browser\lib\net6.0\System.Text.Encodings.Web.dll
2023-07-27 20:50:47,026 8404 [INFO ] - VERBOSE: - runtimes\unix\lib\netcoreapp3.1\Microsoft.Data.SqlClient.dll
2023-07-27 20:50:47,026 8404 [INFO ] - VERBOSE: - runtimes\unix\lib\netcoreapp3.0\System.Drawing.Common.dll
2023-07-27 20:50:47,026 8404 [INFO ] - VERBOSE: - runtimes\win\lib\net6.0\System.Diagnostics.EventLog.Messages.dll
2023-07-27 20:50:47,026 8404 [INFO ] - VERBOSE: - runtimes\win\lib\net6.0\System.ServiceProcess.ServiceController.dll
2023-07-27 20:50:47,041 8404 [INFO ] - VERBOSE: - runtimes\win\lib\net6.0\System.Diagnostics.EventLog.dll
2023-07-27 20:50:47,041 8404 [INFO ] - VERBOSE: - runtimes\win\lib\netcoreapp2.1\System.Security.Cryptography.Pkcs.dll
2023-07-27 20:50:47,041 8404 [INFO ] - VERBOSE: - runtimes\win\lib\netcoreapp3.0\System.Drawing.Common.dll
2023-07-27 20:50:47,041 8404 [INFO ] - VERBOSE: - runtimes\win\lib\netcoreapp3.0\Microsoft.Win32.SystemEvents.dll
2023-07-27 20:50:47,041 8404 [INFO ] - VERBOSE: - runtimes\win\lib\netcoreapp3.1\Microsoft.Data.SqlClient.dll
2023-07-27 20:50:47,041 8404 [INFO ] - VERBOSE: - runtimes\win\lib\netstandard2.0\System.Runtime.Caching.dll
2023-07-27 20:50:47,041 8404 [INFO ] - VERBOSE: - runtimes\win\lib\netstandard2.0\System.Security.Cryptography.ProtectedData.dll
2023-07-27 20:50:47,041 8404 [INFO ] - VERBOSE: - runtimes\win-x64\native\Microsoft.Data.SqlClient.SNI.dll
2023-07-27 20:50:47,041 8404 [INFO ] - VERBOSE: - runtimes\win-x86\native\Microsoft.Data.SqlClient.SNI.dll
2023-07-27 20:50:47,041 8404 [INFO ] - VERBOSE: - runtimes\win\lib\netcoreapp3.0\System.Windows.Extensions.dll
2023-07-27 20:50:47,041 8404 [INFO ] - VERBOSE: - runtimes\win-arm\native\Microsoft.Data.SqlClient.SNI.dll
2023-07-27 20:50:47,057 8404 [INFO ] - VERBOSE: 
2023-07-27 20:50:47,057 8404 [INFO ] - VERBOSE: Sub items Errors: 1
2023-07-27 20:50:47,057 8404 [INFO ] - VERBOSE: 
2023-07-27 20:50:47,057 8404 [INFO ] - VERBOSE: 
2023-07-27 20:50:47,057 8404 [INFO ] - VERBOSE: Sub items Errors: 1
2023-07-27 20:50:47,057 8404 [INFO ] - VERBOSE: Archives with Errors: 1
2023-07-27 20:50:47,057 8404 [ERROR] - ERROR: Unsupported Method : runtimes\win-arm64\native\Microsoft.Data.SqlClient.SNI.dll
2023-07-27 20:50:47,072 8404 [DEBUG] - Command ['C:\ProgramData\chocolatey\tools\7z.exe' x -aoa -bd -bb1 -o"E:\InternalPackage\bin" -y "C:\Users\XX\AppData\Local\Temp\chocolatey\InternalPackage\5.0.0.292\InternalPackage.5.0.0.292.7z"] exited with '2'.
2023-07-27 20:50:47,088 8404 [DEBUG] - 7z exit code: 2
2023-07-27 20:50:47,088 8404 [ERROR] - ERROR: 7-Zip encountered a fatal error while extracting the files. This is most likely an issue with the 'InternalPackage' package and not with Chocolatey itself. Please follow up with the package maintainer(s) directly.

Additional Context

No response

Metadata

Metadata

Assignees

Labels

5 - ReleasedDependency ChangeIf a dependency or bundled binaries are added, removed or updated.

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0