Skip to content

Commit

Permalink
chore: improve blockifier CI trigger and scope
Browse files Browse the repository at this point in the history
Signed-off-by: Dori Medini <dori@starkware.co>
  • Loading branch information
dorimedini-starkware committed Aug 5, 2024
1 parent 87e6d3f commit eb1fda5
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 3 deletions.
11 changes: 10 additions & 1 deletion .github/workflows/blockifier_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ on:
- main-v[0-9].**
tags:
- v[0-9].**
# TODO(Dori, 1/9/2024): Decide when exactly native-blockifier artifacts will be built. Until
# then, keep the 'paths' key empty and build on every push to a release branch / tag.

pull_request:
types:
Expand All @@ -18,10 +20,17 @@ on:
- auto_merge_enabled
- edited
paths:
# Other than code-related changes, all changes related to the native-blockifier build-and-push
# process should trigger the build (e.g., changes to the Dockerfile, build scripts, etc.).
- '.github/workflows/blockifier_ci.yml'
- 'Cargo.toml'
- 'Cargo.lock'
- 'blockifier.Dockerfile'
- 'build_native_blockifier_in_docker.sh'
- 'crates/blockifier/**'
- 'crates/native_blockifier/**'
- 'build_native_blockifier_in_docker.sh'
- 'scripts/build_native_blockifier.sh'
- 'scripts/install_build_tools.sh'

jobs:
featureless-build:
Expand Down
7 changes: 6 additions & 1 deletion .github/workflows/blockifier_compiled_cairo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,22 @@ on:
push:
branches:
- main
- main-v[0-9].**
tags:
- v[0-9].**
paths:
- '.github/workflows/blockifier_compiled_cairo.yml'
- 'crates/blockifier/feature_contracts/cairo0/**'
- 'crates/blockifier/tests/requirements.txt'
pull_request:
types:
- opened
- reopened
- synchronize
paths:
- '.github/workflows/blockifier_compiled_cairo.yml'
- 'crates/blockifier/feature_contracts/cairo0/**'
- 'crates/blockifier/tests/requirements.txt'

jobs:
verify_cairo_file_dependencies:
Expand All @@ -38,4 +43,4 @@ jobs:

- run:
pip install -r crates/blockifier/tests/requirements.txt;
cargo test verify_feature_contracts -- --include-ignored
cargo test -p blockifier verify_feature_contracts -- --include-ignored
4 changes: 4 additions & 0 deletions .github/workflows/blockifier_coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,14 @@ name: Blockifier-Coverage
on:
pull_request:
paths:
- '.github/workflows/blockifier_coverage.yml'
- 'crates/blockifier/**'
- 'crates/native_blockifier/**'
push:
paths:
- '.github/workflows/blockifier_coverage.yml'
- 'crates/blockifier/**'
- 'crates/native_blockifier/**'

jobs:
coverage:
Expand Down
5 changes: 4 additions & 1 deletion .github/workflows/blockifier_post-merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,10 @@ on:
types:
- closed
paths:
- '.github/workflows/blockifier_post-merge.yml'
- 'crates/blockifier/**'
- 'crates/native_blockifier/**'

jobs:
if_merged:
if: github.event.pull_request.merged == true
Expand All @@ -29,4 +32,4 @@ jobs:

- run: |
pip install -r crates/blockifier/tests/requirements.txt
cargo test -- --include-ignored
cargo test -p blockifier -p native_blockifier -- --include-ignored

0 comments on commit eb1fda5

Please sign in to comment.