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

ci: ensure older tests get cancelled on new commit #979

Merged
merged 2 commits into from
Dec 11, 2024

Conversation

tushar-composio
Copy link
Collaborator

@tushar-composio tushar-composio commented Dec 11, 2024

Important

Add concurrency control to GitHub Actions workflows to cancel older runs on new commits in common.yml.

  • Concurrency Control:
    • Added concurrency to lock_check, linter_checks, and test jobs in common.yml.
    • Uses group: 'test:common:${{ github.ref }}' to group jobs by branch.
    • cancel-in-progress: true ensures older runs are cancelled on new commits.

This description was created by Ellipsis for 0fb65d6. It will automatically update as commits are pushed.

Copy link

vercel bot commented Dec 11, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
composio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 11, 2024 8:04am

Copy link
Contributor

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

❌ Changes requested. Reviewed everything up to 0fb65d6 in 37 seconds

More details
  • Looked at 34 lines of code in 1 files
  • Skipped 0 files when reviewing.
  • Skipped posting 0 drafted comments based on config settings.

Workflow ID: wflow_qhRVmSVkK0PZ7tRl


Want Ellipsis to fix these issues? Tag @ellipsis-dev in a comment. You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

@@ -17,6 +17,9 @@ jobs:
os: [ubuntu-latest]
python-version: ["3.10"]
timeout-minutes: 10
concurrency:
group: 'test:common:${{ github.ref }}'
Copy link
Contributor

Choose a reason for hiding this comment

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

The concurrency group name 'test:common:${{ github.ref }}' is used for all jobs. This might cause unintended cancellations across different jobs. Consider using unique group names for each job, like 'lock_check', 'linter_checks', etc.

@@ -77,6 +83,9 @@ jobs:
os: [ubuntu-latest]
python-version: ["3.9", "3.10", "3.11"]
timeout-minutes: 20
concurrency:
group: 'test:common:${{ github.ref }}'
Copy link
Collaborator

Choose a reason for hiding this comment

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

Consider making the concurrency group name more specific by including the job name and Python version to allow parallel runs of different jobs:

group: 'test:${{ github.job }}:${{ matrix.python-version }}:${{ github.ref }}'

This would allow different Python versions to run in parallel while still cancelling redundant runs of the same version.

@shreysingla11
Copy link
Collaborator

Code Review Summary

Overall Assessment

The changes look good and implement a useful optimization for the CI pipeline. The addition of concurrency controls will help prevent resource waste and provide clearer test results by cancelling outdated runs.

Positive Aspects

✅ Consistent implementation across all jobs
✅ Well-structured concurrency configuration
✅ No disruption to existing functionality
✅ Will improve CI resource utilization

Suggestions for Improvement

  • Consider making concurrency groups more specific (per job and Python version) to allow parallel runs where beneficial
  • Adding a brief comment explaining the concurrency configuration would help future maintainers

Verdict

The changes are well-implemented and will improve the CI pipeline's efficiency. Approved with minor optional suggestions for enhancement.

Copy link

github-actions bot commented Dec 11, 2024

This comment was generated by github-actions[bot]!

JS SDK Coverage Report

📊 Coverage report for JS SDK can be found at the following URL:
https://pub-92e668239ab84bfd80ee07d61e9d2f40.r2.dev/coverage-12272099753/coverage/index.html

📁 Test report folder can be found at the following URL:
https://pub-92e668239ab84bfd80ee07d61e9d2f40.r2.dev/html-report-12272099753/html-report/report.html

@tushar-composio tushar-composio merged commit b98afd5 into master Dec 11, 2024
9 of 10 checks passed
@tushar-composio tushar-composio deleted the cancel-older-tests branch December 11, 2024 08:21
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

Successfully merging this pull request may close these issues.

2 participants