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

Release 4.20.0 #2223

Merged
merged 1 commit into from
Apr 25, 2024
Merged

Release 4.20.0 #2223

merged 1 commit into from
Apr 25, 2024

Conversation

VietND96
Copy link
Member

@VietND96 VietND96 commented Apr 25, 2024

User description

[deploy]

Thanks for contributing to the Docker-Selenium project!
A PR well described will help maintainers to quickly review and merge it

Before submitting your PR, please check our contributing guidelines, applied for this repository.
Avoid large PRs, help reviewers by making them as simple and short as possible.

Description

Motivation and Context

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • I have read the contributing document.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

Type

enhancement, configuration changes


Description

  • Added retry logic with a 60-second wait in multiple GitHub Actions workflows to enhance the robustness of Docker image builds.
  • Introduced steps to set Selenium base version in workflows when not deploying, improving the build process's adaptability.
  • Updated Makefile and test matrices to align with the new Selenium version 4.20.0.

Changes walkthrough

Relevant files
Enhancement
build-test.yml
Enhance GitHub Actions for Build Test Workflow                     

.github/workflows/build-test.yml

  • Added a step to set Selenium base version if the commit does not
    contain '[deploy]'
  • Added retry logic with a 60-second wait to the Docker image build
    process
  • +6/-2     
    helm-chart-test.yml
    Update Helm Chart Test Workflow with New Steps and Retry Logic

    .github/workflows/helm-chart-test.yml

  • Added a step to set Selenium base version if the commit does not
    contain '[deploy]'
  • Modified environment variables setup and added retry logic for Docker
    image build
  • +6/-2     
    test-video.yml
    Enhance Test Video Workflow with New Setup and Retry Logic

    .github/workflows/test-video.yml

  • Added a step to set Selenium base version if the commit does not
    contain '[deploy]'
  • Enhanced Docker image build process with retry logic
  • +6/-2     
    Configuration changes
    deploy.yml
    Update Deploy Workflow with Retry Logic                                   

    .github/workflows/deploy.yml

  • Implemented retry logic with a 60-second wait for the Docker image
    build process
  • +6/-1     
    nightly.yaml
    Implement Retry Logic in Nightly Build Workflow                   

    .github/workflows/nightly.yaml

  • Added retry logic with a 60-second wait for the Docker image build
    process
  • +6/-1     
    Makefile
    Update Makefile for New Selenium Version 4.20.0                   

    Makefile

  • Updated BASE, BINDING, and VERSION variables to reflect new version
    4.20.0
  • +5/-5     
    selenium-matrix.yml
    Update Selenium Matrix for Backward Compatibility Testing

    tests/build-backward-compatible/selenium-matrix.yml

  • Updated the matrix to include new version 4.20.0 and updated snapshot
    version to 4.21.0-SNAPSHOT
  • +11/-2   

    PR-Agent usage:
    Comment /help on the PR to get a list of all available PR-Agent tools and their descriptions

    [deploy]
    
    Signed-off-by: Viet Nguyen Duc <[email protected]>
    Copy link

    PR Description updated to latest commit (e524adc)

    Copy link

    PR Review

    ⏱️ Estimated effort to review [1-5]

    3, because the PR includes multiple changes across various workflow files and the Makefile, impacting build and deployment processes. The changes are not overly complex but require careful review to ensure they don't disrupt existing CI/CD pipelines.

    🧪 Relevant tests

    No

    🔍 Possible issues

    Possible Bug: The condition if: contains(toJson(github.event.commits), '[deploy]') == false used in workflow files might not work as expected if the commit message formatting changes or if multiple commits are included in the push that triggers the workflow.

    Dependency on External Action: The PR heavily relies on nick-invision/retry@master. Using a master branch reference can lead to breaking changes if the action is updated. It's safer to use a specific version or commit hash.

    🔒 Security concerns

    No


    ✨ Review tool usage guide:

    Overview:
    The review tool scans the PR code changes, and generates a PR review which includes several types of feedbacks, such as possible PR issues, security threats and relevant test in the PR. More feedbacks can be added by configuring the tool.

    The tool can be triggered automatically every time a new PR is opened, or can be invoked manually by commenting on any PR.

    • When commenting, to edit configurations related to the review tool (pr_reviewer section), use the following template:
    /review --pr_reviewer.some_config1=... --pr_reviewer.some_config2=...
    
    [pr_reviewer]
    some_config1=...
    some_config2=...
    

    See the review usage page for a comprehensive guide on using this tool.

    Copy link

    PR Code Suggestions

    CategorySuggestions                                                                                                                                                       
    Best practice
    Use a specific version tag for GitHub Actions to ensure stability.

    Consider using a specific version tag instead of 'master' for the 'nick-invision/retry'
    action to ensure stability and predictability in your CI workflows.

    .github/workflows/build-test.yml [56]

    -uses: nick-invision/retry@master
    +uses: nick-invision/retry@v2
     
    Add error handling to critical shell commands.

    It's recommended to handle potential failures in shell commands. Consider adding error
    handling for the 'docker login' command.

    .github/workflows/deploy.yml [63]

    -run: docker login -u="$DOCKER_USERNAME" -p="$DOCKER_PASSWORD"
    +run: docker login -u="$DOCKER_USERNAME" -p="$DOCKER_PASSWORD" || echo "Docker login failed"
     
    Specify the timezone in date commands to avoid timezone issues.

    To avoid potential issues with timezone differences, specify the timezone when using the
    'date' command.

    .github/workflows/nightly.yaml [68]

    -echo "BUILD_DATE=$(date '+%Y%m%d')" >> $GITHUB_ENV
    +echo "BUILD_DATE=$(date '+%Y%m%d' -u)" >> $GITHUB_ENV
     
    Maintainability
    Align YAML indentation for better readability and maintainability.

    To improve the readability and maintainability of the YAML file, consider aligning the
    indentation of the 'env' block with its sibling keys.

    .github/workflows/helm-chart-test.yml [108-109]

     env:
    -  AUTHORS: ${{ vars.AUTHORS || 'SeleniumHQ' }}
    +    AUTHORS: ${{ vars.AUTHORS || 'SeleniumHQ' }}
     
    Use a single version variable to reduce duplication and improve maintainability.

    For better maintainability and to avoid duplication, consider using a single variable for
    the version number that is reused across different variables.

    Makefile [5-9]

    -BASE_VERSION := $(or $(BASE_VERSION),$(BASE_VERSION),4.20.0)
     VERSION := $(or $(VERSION),$(VERSION),4.20.0)
    +BASE_VERSION := $(VERSION)
     

    ✨ Improve tool usage guide:

    Overview:
    The improve tool scans the PR code changes, and automatically generates suggestions for improving the PR code. The tool can be triggered automatically every time a new PR is opened, or can be invoked manually by commenting on a PR.

    • When commenting, to edit configurations related to the improve tool (pr_code_suggestions section), use the following template:
    /improve --pr_code_suggestions.some_config1=... --pr_code_suggestions.some_config2=...
    
    [pr_code_suggestions]
    some_config1=...
    some_config2=...
    

    See the improve usage page for a comprehensive guide on using this tool.

    @VietND96 VietND96 merged commit a5e7692 into SeleniumHQ:trunk Apr 25, 2024
    11 checks passed
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Projects
    None yet
    Development

    Successfully merging this pull request may close these issues.

    1 participant