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

Upgrade chrome browser on windows self hosted machine #532

Closed
ushankar5586 opened this issue May 3, 2024 · 3 comments
Closed

Upgrade chrome browser on windows self hosted machine #532

ushankar5586 opened this issue May 3, 2024 · 3 comments

Comments

@ushankar5586
Copy link

Hello, I am using below steps in the yaml file

steps:
  - uses: browser-actions/setup-chrome@v1
  - run: chrome --version

I am getting this below error so can you please help on how to resolve it

Installing chromium...
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\443364dc-97fa-4064-81fa-e058cf6f5530' -DestinationPath 'C:\actions-runner\_work\_temp\fac04576-0e61-46ff-be44-c842022bb30d' -Force } else {[System.IO.Compression.ZipFile]::ExtractToDirectory('C:\actions-runner\_work\_temp\443364dc-97fa-4064-81fa-e058cf6f5530', 'C:\actions-runner\_work\_temp\fac04576-0e61-46ff-be44-c842022bb30d', $true) }"
Expand-Archive :  is not a supported archive file format. .zip is the only supported archive file format.
At line:1 char:210
+ ...  Ignore)) { Expand-Archive -LiteralPath 'C:\actions-runner\_work\_tem ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (:String) [Expand-Archive], IOException
    + FullyQualifiedErrorId : NotSupportedArchiveFileExtension,Expand-Archive
@ushankar5586
Copy link
Author

Thanks @ueokande Updating powershell resolve the above issue.
So now after running this command -
Run ```
browser-actions/setup-chrome@v1.6.0
with:
chrome-version: latest

i am getting this message - Successfully setup chromium version 127.0.6495.0 
but when test is starting i am getting this message -  
Error Message:
   System.InvalidOperationException : session not created: This version of ChromeDriver only supports Chrome version 125
Current browser version is 124.0.6367.208 with binary path C:\Program Files\Google\Chrome\Application\chrome.exe
What could be the reason?

@ueokande
Copy link
Collaborator

The issue is caused by the incompatibility issue between Chrome and Chrome Driver. I think you install the latest Google Chrome by our action, but your test executes the pre-installed ChromeDriver in the GitHub Runner. You need to install a compatible version of ChromeDriver for Chrome 127.0.6495.0 before you run tests. Please refer to the ChromeDriver document to choose the correct version of ChromeDriver. We will track this issue in #527

Thank you.

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

No branches or pull requests

2 participants