hardkoded / puppeteer-sharp

Headless Chrome .NET API
https://www.puppeteersharp.com
MIT License
3.36k stars 440 forks source link

Chromium downloads broken for Platform Windows #2653

Closed dammitjanet closed 3 months ago

dammitjanet commented 3 months ago

Description

If you try an download Chromium on Windows (Platform Win32 or Win64), both cannot be found and results in an error

An unhandled exception occurred while processing the request. HttpRequestException: Response status code does not indicate success: 404 (Not Found). System.Net.Http.HttpResponseMessage.EnsureSuccessStatusCode()

PuppeteerException: Failed to download Chromium for Win64 from https://storage.googleapis.com/chromium-browser-snapshots/Win_x64/124.0.6367.201/chrome-win32.zip

Complete minimal example reproducing the issue

            var browserFetcherOptions = new BrowserFetcherOptions
            {
                Browser = SupportedBrowser.Chromium,
                Platform = Platform.Win64
            };

            var browserFetcher = new BrowserFetcher(browserFetcherOptions);
            await browserFetcher.DownloadAsync();

Expected behavior:

The BrowserFetcher to get the requested browser

Actual behavior:

An error is thrown,

PuppeteerException: Failed to download Chromium for Win64 from https://storage.googleapis.com/chromium-browser-snapshots/Win_x64/124.0.6367.201/chrome-win32.zip

Versions

Additional Information

the correct url for the latest Chromium build appears to be,

https://storage.googleapis.com/chromium-browser-snapshots/Win_x64/1310601/chrome-win.zip

not sure even where the buildId of 124.0.6367.201 comes from as https://storage.googleapis.com/chromium-browser-snapshots/Win_x64/LAST_CHANGE results in 1310601 as of today

kblok commented 3 months ago

Fixing!

kblok commented 3 months ago

@dammitjanet v18.0.1 shipped with the fix.

dammitjanet commented 3 months ago

perfect, and thank you for the quick fix