Skip to content
Merged
Show file tree
Hide file tree
Changes from 11 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions .github/workflows/ci-test-custom-script.yml
Original file line number Diff line number Diff line change
Expand Up @@ -255,10 +255,14 @@ jobs:
./cypress/setup-test-ci.sh

- uses: browser-actions/setup-chrome@latest
id: setup-chrome
with:
chrome-version: stable
chrome-version: 129

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codebase verification

Chrome 129 is compatible but consider using version range

Chrome 129 is a stable version and compatible with Cypress 13.13.0, but fixing to a specific version might be restrictive. Consider using a version range (e.g., >= 129.0.0) to get security updates while maintaining stability.

  • Update line 259 to use chrome-version: '>=129.0.0' for better maintainability and security
🔗 Analysis chain

Verify Chrome version 129 compatibility

Fixing the Chrome version can help with test stability, but version 129 needs verification:

  1. Ensure it's compatible with your Cypress version
  2. Consider potential security implications of using a fixed version

Let me analyze the Cypress configuration to ensure compatibility with Chrome 129. The previous results confirm Chrome 129 is a stable version, but we need to verify Cypress compatibility.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check if Chrome 129 is a stable version and get its release date
curl -s https://versionhistory.googleapis.com/v1/chrome/platforms/linux/channels/stable/versions | jq -r '.versions[] | select(.version | startswith("129"))'

# Check Cypress compatibility matrix
curl -s https://raw.githubusercontent.com/cypress-io/cypress-documentation/develop/content/guides/references/browser-launch-api.md | grep -A 5 "Chrome version support"

Length of output: 763


Script:

#!/bin/bash
# Let's check the Cypress configuration and version in the repository
fd -e json package.json --exec cat {} | jq -r 'select(.dependencies.cypress or .devDependencies.cypress) | .dependencies.cypress, .devDependencies.cypress'

# Check if there are any Cypress configuration files
fd -e json -e js cypress.config

Length of output: 206

install-chromedriver: true
install-dependencies: true
- run: |
echo "BROWSER_PATH=$(which chrome)" >> $GITHUB_ENV
echo "BROWSER_PATH=${{ steps.setup-chrome.outputs.chrome-path }}" >> $GITHUB_ENV
${{ steps.setup-chrome.outputs.chrome-path }} --version

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codebase verification

⚠️ Potential issue

Chrome version 129 is not yet released and may cause issues

The current stable Chrome version is 120. Using an unreleased version (129) could cause compatibility issues with Cypress and affect test reliability. Please use Chrome version 120 instead.

  id: setup-chrome
  with:
-   chrome-version: 129
+   chrome-version: 120
    install-chromedriver: true
    install-dependencies: true
🔗 Analysis chain

Chrome version 129 is not yet released and may cause issues

The current stable Chrome version is 120. Using an unreleased version (129) could cause compatibility issues with Cypress and affect snapshot testing reliability.

Apply this diff to fix the Chrome version:

  with:
-   chrome-version: 129
+   chrome-version: 120
    install-chromedriver: true
    install-dependencies: true
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Verify Chrome version compatibility with Cypress
fd -e json package.json --exec jq -r '.dependencies.cypress, .devDependencies.cypress'

# Check Cypress configuration for browser settings
fd -e json -e js cypress.config --exec cat {}

Length of output: 291


Script:

#!/bin/bash
# Check for any browser-related configurations in package.json files
fd -e json package.json --exec grep -l "browser\|chrome" {} | xargs cat

# Search for browser configuration in any test setup files
rg -g "!node_modules" -g "!dist" -l "browser.+config|chrome.+config" 

# Look for any Playwright or Selenium configurations
fd -e config.js -e config.ts -e config.json --exec grep -l "browser\|chrome" {}

# Check GitHub workflow files for browser-related jobs
fd workflow -e yml -e yaml --exec grep -A 5 -B 5 "chrome-version:" {}

Length of output: 15487


Script:

#!/bin/bash
# Check Cypress configuration files for browser settings
cat app/client/cypress.config.ts app/client/cypress_ci.config.ts app/client/cypress_ci_custom.config.ts

# Look for Chrome version references in workflow files
fd -e yml -e yaml . --exec cat {} | grep -A 10 -B 10 "chrome-version:"

Length of output: 4963


Script:

#!/bin/bash
# Search for Chrome version in GitHub workflow files directly
find .github/workflows -type f -name "*.yml" -exec cat {} \;

# Check for any Chrome-related environment variables in workflow files
find .github/workflows -type f -exec grep -l "chrome" {} \;

Length of output: 67658


Script:

#!/bin/bash
# Search for Chrome version in ci-test-custom-script.yml
cat .github/workflows/ci-test-custom-script.yml

# Check for any Cypress browser configuration files
fd -e json -e js -e ts -g "!node_modules" -g "!dist" --exec grep -l "browser.*config\|chrome.*config" {}

Length of output: 21044

🧰 Tools
🪛 actionlint (1.7.4)

263-263: shellcheck reported issue in this script: SC2086:info:1:70: Double quote to prevent globbing and word splitting

(shellcheck)


- name: Save Git values
# pass env variables from this step to other steps
Expand Down Expand Up @@ -366,7 +370,7 @@ jobs:
CYPRESS_STATIC_ALLOCATION: true
DEBUG: ${{secrets.CYPRESS_GREP_DEBUG }} # This is derived from secrets so that we can toggle it without having to change any workflow. Only acceptable value is: @cypress/grep
with:
browser: ${{ env.BROWSER_PATH }}
browser: chrome
install: false
config-file: cypress_ci_custom.config.ts
spec: ${{ inputs.spec }}
Expand Down
8 changes: 6 additions & 2 deletions .github/workflows/ci-test-hosted.yml
Original file line number Diff line number Diff line change
Expand Up @@ -138,10 +138,14 @@ jobs:
./cypress/setup-test-ci.sh

- uses: browser-actions/setup-chrome@latest
id: setup-chrome
with:
chrome-version: stable
chrome-version: 129

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codebase verification

Chrome version 129 is too far ahead of current stable releases

The project uses Cypress 13.13.0 for testing, and Chrome 129 is not yet released (current stable is 120). Using unreleased browser versions in CI can lead to instability.

  • Recommend using Chrome version 120 or lower to match current stable releases
  • Update .github/workflows/ci-test-hosted.yml line 142
🔗 Analysis chain

Verify Chrome version compatibility with test suite

The change to Chrome version 129 should be validated against the test suite requirements and browser compatibility matrix.

Consider implementing browser version compatibility checks in the test suite to prevent issues with future version updates.


Let me check the specific browser version requirements in these files.


Let me check the Cypress configuration to understand browser testing requirements.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Check Chrome version compatibility with test suite
# Look for any browser version specific code or configurations
rg -g '*.{ts,js,json}' -l 'chrome.*version|browser.*version' app/client/

Length of output: 261


Script:

#!/bin/bash
# Check the content of files for Chrome version references
rg -g '*.{ts,js,json}' 'chrome.*version|browser.*version' app/client/test/factories/MockPluginsState.ts
rg -g '*.{ts,js,json}' 'chrome.*version|browser.*version' app/client/cypress/fixtures/CommunityIssuesExport.json

# Check package.json for any browser dependencies
rg -g 'package.json' '"(cypress|playwright|puppeteer|selenium)"' .

# Check for any browser configuration in Cypress
fd -g 'cypress.config.*' .

Length of output: 66731


Script:

#!/bin/bash
# Check Cypress configuration and browser settings
fd -t f -e json -e js cypress.config
fd -t f package.json -x cat {} \; | grep -A 5 -B 5 '"cypress":'

Length of output: 520

install-chromedriver: true
install-dependencies: true
- run: |
echo "BROWSER_PATH=$(which chrome)" >> $GITHUB_ENV
echo "BROWSER_PATH=${{ steps.setup-chrome.outputs.chrome-path }}" >> $GITHUB_ENV
${{ steps.setup-chrome.outputs.chrome-path }} --version

- name: Save Git values
# pass env variables from this step to other steps
Expand Down
8 changes: 6 additions & 2 deletions .github/workflows/ci-test-limited-with-count.yml
Original file line number Diff line number Diff line change
Expand Up @@ -231,10 +231,14 @@ jobs:
./cypress/setup-test-ci.sh

- uses: browser-actions/setup-chrome@latest
id: setup-chrome
with:
chrome-version: stable
chrome-version: 129
install-chromedriver: true
install-dependencies: true
- run: |
echo "BROWSER_PATH=$(which chrome)" >> $GITHUB_ENV
echo "BROWSER_PATH=${{ steps.setup-chrome.outputs.chrome-path }}" >> $GITHUB_ENV
${{ steps.setup-chrome.outputs.chrome-path }} --version

- name: Save Git values
# pass env variables from this step to other steps
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/ci-test-limited.yml
Original file line number Diff line number Diff line change
Expand Up @@ -220,12 +220,16 @@ jobs:
cd app/client
chmod a+x ./cypress/setup-test-ci.sh
./cypress/setup-test-ci.sh

- uses: browser-actions/setup-chrome@latest
id: setup-chrome
with:
chrome-version: stable
chrome-version: 129
install-chromedriver: true
install-dependencies: true
- run: |
echo "BROWSER_PATH=$(which chrome)" >> $GITHUB_ENV
echo "BROWSER_PATH=${{ steps.setup-chrome.outputs.chrome-path }}" >> $GITHUB_ENV
${{ steps.setup-chrome.outputs.chrome-path }} --version

- name: Save Git values
# pass env variables from this step to other steps
Expand Down