evergreen icon indicating copy to clipboard operation
evergreen copied to clipboard

[Bug]: The Download size for 7zip is incorrect

Open j81blog opened this issue 1 year ago • 2 comments

What happened?

Get-EvergreenApp -Name 7zip | Where-Object{$_.Architecture -eq 'x64' -and $_.Type -like 'msi' } | Save- EvergreenApp -CustomPath C:\temp

If I use the same URI to dowmload the file I get the sourcefourge "info" page with a counter. Then I'm being presented with the download and get the right file with right size. Lookls like downloadg via PowerShell doesn't work anymore.

Version

2405.1076

What PowerShell edition/s are you running Evergreen on?

PowerShell Core, Windows PowerShell

Which operating system/s are you running Evergreen on?

Windows 10+, Windows Server 2016+

Have you reviewed the documentation?

  • [X] Troubleshooting at: https://stealthpuppy.com/evergreen/troubleshoot/
  • [X] Known issues at: https://stealthpuppy.com/evergreen/issues/

Verbose output

VERBOSE: Path exists: C:\Temp.
VERBOSE: URL: https://altushost-swe.dl.sourceforge.net/project/sevenzip/7-Zip/24.06/7z2406-x64.msi.
VERBOSE: Performing the operation "Download" on target
"https://altushost-swe.dl.sourceforge.net/project/sevenzip/7-Zip/24.06/7z2406-x64.msi".
VERBOSE: GET https://altushost-swe.dl.sourceforge.net/project/sevenzip/7-Zip/24.06/7z2406-x64.msi with 0-byte payload
VERBOSE: received -1-byte response of content type text/html; charset=utf-8
VERBOSE: Successfully downloaded:
C:\Temp\7z2406-x64.msi.


    Directory: C:\Temp


Mode                LastWriteTime         Length Name
----                -------------         ------ ----
-a----        14-6-2024     13:28         112468 7z2406-x64.msi
VERBOSE: Complete.
VERBOSE: Performing the operation "Save-EvergreenApp" on target "Remove variables".

j81blog avatar Jun 14 '24 11:06 j81blog

See #692 and #677

aaronparker avatar Jun 14 '24 13:06 aaronparker

Had the same issue, I had to edit the download uri slightly to Invoke-WebRequest -Uri $($DownloadURI + "?viasf=1") I had to add an if statement. If $DownloadURI -like "sourceforge.net do the above url edit.

Having visited the sourceforge.net using the new uri https://deac-riga.dl.sourceforge.net/project/sevenzip/7-Zip/24.06/7z2406-x64.msi it does a redirect to https://deac-riga.dl.sourceforge.net/project/sevenzip/7-Zip/24.06/7z2406-x64.msi?viasf=1 which then downloads the full file as normal.

This overall issue will affect all applications sourced from sourceforge.net as I had the same issue with WINSCP

Has anyone found a better a solution, if so please let me know

Cyanic-Cloud avatar Jun 26 '24 12:06 Cyanic-Cloud

Closing duplicate. Use: https://github.com/aaronparker/evergreen/issues/677

aaronparker avatar Jul 07 '24 09:07 aaronparker