Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
200 commits
Select commit Hold shift + click to select a range
b0093d9
Enhance CI Workflow for Scenic Simulators: Improved Volume Management…
lola831 Nov 1, 2024
4ae8ee2
Newtonian Simulator Fixes and Cleanup (#309)
Eric-Vin Nov 5, 2024
fe28e13
Fix requirements inside loops and functions (#316)
dfremont Nov 26, 2024
b84d833
chore: include supported version of Webots in docs (#266)
abanuelo Dec 13, 2024
a6e48a2
feat: Adding M1/Intel runners to `run-tests.yml` and introducing fast…
abanuelo Dec 13, 2024
26d9da7
feat: enable dynamic scenario termination from closing display (#249)
abanuelo Dec 17, 2024
9d82eda
chore: Updating webots examples (#263)
abanuelo Dec 17, 2024
ca74ae9
chore: Updating examples for CARLA and driving domain (#257)
abanuelo Dec 18, 2024
8a2a7e9
feat: adding webots dynamic scenario tests (#231)
abanuelo Dec 20, 2024
dcd0213
Apply black and isort to test-webots file (#324)
lola831 Jan 14, 2025
8495cc9
Use zizmor to scan for GHA security problems (#320)
dfremont Jan 22, 2025
394f205
Remove OpsGenie and maintenance bot on-call reminder script and workf…
lola831 Feb 13, 2025
f6bb62a
Add support for Python 3.13 (#328)
dfremont Feb 14, 2025
1487693
Update CI for Python 3.13 (#329)
lola831 Mar 5, 2025
4b74848
Feat: Initial MetaDrive Integration (#326)
lola831 Mar 6, 2025
5d36cce
fix: update pyglet constraint to allow 2.0.18 with Apple Silicon fix …
lola831 Mar 21, 2025
0727a6c
Update all workflows to reference fixed commit hashes instead of floa…
lola831 Apr 4, 2025
b72430c
Use shapely.points instead of shapely.lib.points (#336)
lola831 Apr 7, 2025
c8aad62
Raise ValueError for missing sumo_map in MetaDriveSimulator initializ…
lola831 Apr 11, 2025
6afd8e8
Create CODE_OF_CONDUCT.md (#337)
lola831 Apr 15, 2025
74a8fdc
Add governance and roadmap pages to documentation (#342)
dfremont Apr 16, 2025
4ecc20b
Improve Carla Autopilot configuration for Scenic (#332)
sdhar16 Apr 16, 2025
9d1e52d
Various optimizations (#319)
dfremont Apr 17, 2025
56608ba
Temporarily skip test_mesh_interiorPoint due to inconsistencies (#344)
lola831 Apr 28, 2025
17404e0
Add support for initial velocity in MetaDrive simulations (#340)
lola831 Apr 29, 2025
c1003e9
Add dynamic pedestrian example and helper function; render MetaDrive …
lola831 May 12, 2025
44a8442
Constrain pyglet to >=1.5, <=1.5.26 to avoid trimesh and macOS compat…
lola831 May 23, 2025
5ebdf46
Run tests weekly + Slack notification (#347)
lola831 Jun 2, 2025
14cba62
PathRegion/PolygonalFootprint Test and Bugfix (#351)
Eric-Vin Jun 10, 2025
e0d7093
Remove unused CameraManager.images to fix memory leak (#353)
lola831 Jun 17, 2025
e1fa8be
MetaDrive: initialize pedestrian velocity on spawn to Scenic starting…
lola831 Jul 15, 2025
a29f794
mark MetaDrive static ped test as slow and graphical (#362)
lola831 Jul 16, 2025
f07b4ee
Add missing CARLA town SUMO maps (#354)
lola831 Jul 16, 2025
3e1f136
Fix boundingPolygon issue and other recent CI errors/warnings (#363)
dfremont Jul 18, 2025
948465b
Add minimum required permissions to GitHub Actions workflows (#366)
lola831 Jul 30, 2025
cf6bbfa
Fix workflow permissions (#368)
dfremont Jul 31, 2025
cda0c45
replace deprecated set-output command (#370)
lola831 Aug 6, 2025
73a34bd
Support pedestrian movement in Newtonian simulator (#359)
lola831 Aug 13, 2025
c076a70
Add screen recording support to MetaDrive interface (#372)
lola831 Aug 20, 2025
aeb63fa
Sensors (#195)
theilem Aug 21, 2025
a2d9242
add note about getting MetaDrive from the repo (#378)
dfremont Aug 21, 2025
e17e6a4
Pin MetaDrive extra to stable commit (#380)
lola831 Sep 9, 2025
add285d
docs: update AST docs to reflect new base class (#385)
lola831 Oct 3, 2025
d2bfb8b
Add wait for and wait until statements (#384)
lola831 Oct 3, 2025
d3c2f65
add reverse test for Carla (#388)
lola831 Oct 3, 2025
bc24951
Fix MetaDrive actions for composed scenarios (#398)
lola831 Oct 10, 2025
e3e7313
Add CARLA vehicle_percentage_speed_difference to autopilot (#389)
lola831 Oct 10, 2025
40d8d1d
Document steering convention (positive = right) and add CARLA/MetaDri…
lola831 Oct 10, 2025
f83865c
Add compositional scenario test (MetaDrive) (#399)
lola831 Nov 10, 2025
cc36c1a
add test to ensure obj == self inside behavior over simulation().obje…
lola831 Nov 11, 2025
20292f3
add chained comparison tests (#403)
lola831 Nov 11, 2025
1354ff6
ci: replace gha macos-13 runner with macos-15-intel (#410)
lola831 Nov 14, 2025
e093379
update carla docs to include 0.9.16 (#411)
lola831 Nov 14, 2025
aa67db9
pre-main merge
Kv139 Nov 21, 2025
54cfcbb
Handle straight-road SUMO maps in Metadrive film size (#423)
lola831 Nov 26, 2025
3a07fa0
skip MetaDrive tests when assets download fails (#424)
lola831 Nov 26, 2025
b300c6a
Normalize token/indent errors to ScenicParseError and pass filename i…
lola831 Dec 11, 2025
d76f367
Add shoulderAt and make roadDirection & elementAt include shoulders (…
lola831 Dec 11, 2025
f0e3e60
Implement missing driving domain actions in MetaDrive interface (#387)
lola831 Dec 12, 2025
f1f33ec
Derive default velocity from speed and orientation (#427)
lola831 Dec 16, 2025
e24aa16
fix incorrect 'forgot new' errors for operator-like specifiers (#426)
lola831 Dec 16, 2025
73a3580
make MetaDrive composed scenario test deterministic (#420)
lola831 Dec 16, 2025
c880a55
Include map options in road network cache (#425)
lola831 Dec 16, 2025
94c55d8
Prepare for 3.1.0 release (#428)
lola831 Dec 17, 2025
c59621d
make blueprint spawn deterministic (#430)
lola831 Dec 17, 2025
8a2081a
Fix sensors example (#429)
dfremont Dec 18, 2025
156b54b
Fix MetaDrive dependency for 3.1.0 release (#431)
lola831 Dec 18, 2025
8a2abb2
fixed typo in 'release_cosim_road'
Kv139 Feb 3, 2026
4ce467b
generate lane mappings
Kv139 Feb 5, 2026
f6c4b4d
cosim model
Kv139 Feb 5, 2026
c3ceeef
carla client fix
Kv139 Feb 5, 2026
ae798e4
init
Kv139 Feb 5, 2026
714e37b
CoSim maps
Kv139 Feb 5, 2026
1d0dcdd
updated ID and UID for Lanes
Kv139 Feb 5, 2026
321a383
updated .gitignore
Kv139 Feb 5, 2026
e5800e3
minor
Kv139 Feb 5, 2026
69225e4
helper for checking spawn conditions
Kv139 Feb 11, 2026
4640f9b
init
Kv139 Feb 11, 2026
5b4085e
init
Kv139 Feb 11, 2026
cd00be1
init
Kv139 Feb 11, 2026
9f1ccf1
Fix TrackWaypointAction and CARLA test (#435)
lola831 Feb 21, 2026
ec1fe44
tests for take None and take () actions (#409)
lola831 Feb 21, 2026
cc91206
tests: object creations inside list and dict literals (#407)
lola831 Feb 21, 2026
10adc2b
verify invariants are checked after actions in try-interrupt (#406)
lola831 Feb 21, 2026
72c8800
add error cases for random in filter lambdas (#404)
lola831 Feb 21, 2026
29647ef
add test for do with tuple behaviors (#413)
lola831 Feb 21, 2026
98448b2
add test using 'simulator' as a variable name (#412)
lola831 Feb 21, 2026
13e083b
Test TupleDistribution coercion to Vector (#414)
lola831 Feb 22, 2026
6f54450
tests for multiline precond and invariants (#408)
lola831 Feb 22, 2026
cbc265d
Fix `occupiedSpace` heuristic to account for mutations (#436)
Eric-Vin Feb 24, 2026
a97c99e
Include OpenDRIVE header offset when computing scenic_offset in MetaD…
lola831 Mar 6, 2026
0bcc909
updated metsr client
Kv139 Mar 9, 2026
c4177f6
signal map generation + utilities
Kv139 Mar 9, 2026
bd689a3
added traffic flows
Kv139 Mar 9, 2026
37dd061
minor
Kv139 Mar 9, 2026
c344c52
updated docs, light synchronization support added,
Kv139 Mar 9, 2026
71df365
debug failed trajectory
Kv139 Mar 9, 2026
069b3ec
minor
Kv139 Mar 9, 2026
920043c
Fixed simulator synchronization
Kv139 Mar 10, 2026
1798eaa
Add test for Scenic 'new' in list subexpression (#415)
lola831 Mar 13, 2026
07625cb
Fix global parameters in modular scenarios (#442)
dfremont Mar 14, 2026
3122915
merged in globalParam fix
Kv139 Mar 16, 2026
3295ef7
compositional scenario test case
Kv139 Mar 16, 2026
b4f9bc3
minor
Kv139 Mar 16, 2026
d229dc4
fixed ego spawn logic
Kv139 Mar 16, 2026
a6517fd
updated readme
Kv139 Mar 16, 2026
03858a3
template script to spin up metsr
Kv139 Mar 16, 2026
b3ae21f
Update readme with improved formatting and clarity
Kv139 Mar 16, 2026
8abd7b2
Fix errors & warnings for compose blocks (#443)
dfremont Mar 17, 2026
a2db667
added special handling for connecting lanes between intersections
Kv139 Mar 17, 2026
76de20b
Fix coverage handling for stuck scenario warning (#444)
lola831 Mar 17, 2026
26cc8df
merged in modular scenario fixes
Kv139 Mar 18, 2026
8392903
updated metsr interface with client changes
Kv139 Mar 18, 2026
0d17dfc
updated metsr spawn logic
Kv139 Mar 18, 2026
126e11c
merged in client updates
Kv139 Mar 18, 2026
83b02b6
updated model
Kv139 Mar 18, 2026
3a3d4db
Merge branch 'METSRSim' of https://github.com/Kv139/Scenic into METSRSim
Kv139 Mar 18, 2026
164ad62
Generate CARLA blueprints dynamically (#401)
lola831 Mar 31, 2026
ffafcd1
Improve test_docs pre-check with Intersphinx URLs (#419)
lola831 Mar 31, 2026
29f8bd1
Add tests for subclassing Point or OrientedPoint instead of Object (#…
lola831 Mar 31, 2026
a3566d8
Improved overhead for synchronization
Kv139 Apr 2, 2026
d23d3f3
dynamic bubble region
Kv139 Apr 2, 2026
02239e2
Merge remote-tracking branch 'origin/main' into METSRSim
Kv139 Apr 2, 2026
6cfdbc7
Add tests for multiple assignments and unpacking (#402)
lola831 Apr 2, 2026
908d17d
merged in client updates
Kv139 Apr 8, 2026
2386eea
fixed property updates, added lane/intersection caching, updated bubb…
Kv139 Apr 8, 2026
4bbbc5d
Add repository security policy (#449)
lola831 Apr 9, 2026
3c5102e
Add CI workflow for running benchmarks (#341)
lola831 Apr 13, 2026
420386a
Use commit SHAs instead of refs (#456)
lola831 Apr 15, 2026
8801a3b
Fix requirements using locals of top-level modular scenario (#455)
dfremont Apr 16, 2026
1c5b6e3
Improvements to warnings and tests (#453)
dfremont Apr 17, 2026
e51318c
Fix accessing ego and workspace in modular scenarios (#452)
dfremont Apr 17, 2026
3214da5
Require benchmark SHA in comment (#457)
lola831 Apr 17, 2026
d74f61c
Add benchmarks and runner script for CI (#451)
dfremont Apr 18, 2026
3fd35ac
Special handling for deadlocked vehicles and updates to _nearest_lane…
Kv139 Apr 22, 2026
cebae3a
Refactored network management, updated metsr property update logic, c…
Kv139 Apr 23, 2026
66e2b97
fixed trajectory translation bug
Kv139 Apr 23, 2026
1d1ac5e
Updated road and intersection selection logic
Kv139 Apr 24, 2026
ffa0aba
Add fix for the size-based PolygonalRegion containsRegion heuristic. …
Eric-Vin Apr 25, 2026
4ac14ae
updated ego spawn logic, improved bubble object updates and road lookups
Kv139 Apr 30, 2026
615b8e0
fixed lane lookups when metsr recognized road is required, improved …
Kv139 Apr 30, 2026
be35aea
Add Python 3.14 Support (#371)
lola831 May 7, 2026
a8f3bce
Prepare version 3.1.1 (#465)
dfremont May 7, 2026
bdd557c
bump verifai dependency; drop pytest upper bound (#466)
dfremont May 8, 2026
cae39ca
VerifAI Dynamic Sampling Compatibility (#417)
Eric-Vin May 11, 2026
62da37a
Handle inconsistent OpenDRIVE planView lengths (#467)
lola831 May 15, 2026
97a930a
Improve error on object creation in compose blocks; related tweaks (#…
dfremont May 22, 2026
c230f64
cosim actions + base scenarios
Kv139 May 22, 2026
d8596c9
added support for behaviors, updated spawn logic, removed autopilot -…
Kv139 May 22, 2026
4ee8bc8
updated model
Kv139 May 22, 2026
d838c69
fixed lane parsing to check for missing road links and to account for…
Kv139 May 22, 2026
4be87bd
Various OpenDRIVE fixes (#468)
dfremont May 22, 2026
1b5b0c5
move network helpers into its own file
Kv139 May 27, 2026
37aa56a
minor
Kv139 May 27, 2026
90d9f29
updated metsr interface client with current version
Kv139 May 27, 2026
aceb468
minor
Kv139 May 27, 2026
8978df0
cleanup
Kv139 May 27, 2026
288efe8
added error handling related to veh spawns
Kv139 May 27, 2026
caa1358
missing obj spawn error
Kv139 May 27, 2026
5014e83
added client utils
Kv139 May 27, 2026
1913049
cleanup
Kv139 May 27, 2026
aca1b79
Update readme for CoSimulator setup instructions
Kv139 May 27, 2026
87a2d39
fixed non-unique road identification for client synchronization + tra…
Kv139 May 28, 2026
3a8accf
map repair protocol for ensuring consistency
Kv139 May 29, 2026
8f1f620
cleanup
Kv139 May 29, 2026
03d7ec5
State based behaviors
Kv139 May 29, 2026
3c001f9
fixed follow trajectory behavior
Kv139 May 30, 2026
454c8e1
Harden simulator workflow with OIDC and SSM (#461)
lola831 Jun 10, 2026
ddd9a9d
Updated SUMO maps
Kv139 Jun 11, 2026
20eee49
cleanup
Kv139 Jun 11, 2026
409ae73
Fixed state behavior template
Kv139 Jun 11, 2026
8257147
Update black action (#480)
dfremont Jun 16, 2026
a84f4e7
road mapping resolution, behavior consistency upon re-entering the bu…
Kv139 Jun 18, 2026
d822016
Added global_route_planner
Kv139 Jun 23, 2026
5cc75cc
added lane lookup
Kv139 Jun 23, 2026
75303a7
updated model for data retention
Kv139 Jun 23, 2026
1d811eb
updated metsr utils and client
Kv139 Jun 23, 2026
bdb13f2
removed autopilot restrictions
Kv139 Jun 23, 2026
08c1808
patched memory leak
Kv139 Jun 23, 2026
7723679
updated imports
Kv139 Jun 23, 2026
7379dac
added data retention features for case studies
Kv139 Jun 23, 2026
13e3093
cleanup + updated autopilot features
Kv139 Jun 23, 2026
08d043c
Added functionality to set seed via python API
Kv139 Jun 25, 2026
12f60bb
fix `terminate when` and `record` statements in subscenarios
dfremont Jun 26, 2026
ff7c260
modified network visualization
Kv139 Jun 26, 2026
72fad54
added support for hybrid physics mode and relaxed spawn restrictions
Kv139 Jun 26, 2026
d077db6
minor
Kv139 Jun 26, 2026
3847769
updated .gitignore
Kv139 Jun 27, 2026
f4c251b
Allow for string and fstring for record names
Kv139 Jun 30, 2026
91cb0a9
Allow strings for record name/keys
Kv139 Jun 30, 2026
c8e34bd
added metsr visualization support
Kv139 Jul 1, 2026
d8d7b0f
removed unused arguements + metsr visualization features
Kv139 Jul 1, 2026
ef70f62
Updated metsr client and utils
Kv139 Jul 1, 2026
506bb67
consider z-dim in computing target transform location
Kv139 Jul 2, 2026
40100dc
fix spawn failures for maps with elevated roads
Kv139 Jul 2, 2026
4a03870
updated client and util versoin
Kv139 Jul 8, 2026
36db8e5
added metsr visualization
Kv139 Jul 8, 2026
9f70114
minor
Kv139 Jul 8, 2026
9ea1623
added metsr_visualziation port to simulator
Kv139 Jul 8, 2026
cf62d34
Merge branch 'fix_subscenarios' into METSRSim
Kv139 Jul 8, 2026
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
2 changes: 1 addition & 1 deletion .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,4 @@ exclude_lines =

ignore_errors = True
show_missing = True
precision = 2
precision = 2
2 changes: 2 additions & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,5 @@
c6c83f95ff370b75c3ee7130dbd8071bfe8b285a
# Cleaned up test quote spacing
995cd182924dc9e3dbbc941c5b75454ea0cdaaca
# Ran black on entire codebase
cb51d08fda00df5588a418df42d9d652472f505f
44 changes: 44 additions & 0 deletions .github/scripts/run-ssm-command.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
#!/bin/bash

INSTANCE_ID="${1:?Missing instance ID}"
EXECUTION_TIMEOUT="${2:-3600}"

# Build the remote shell script as a JSON array for AWS-RunShellScript.
commands=$(jq -Rs -c 'split("\n") | if .[-1] == "" then .[:-1] else . end')

# Run the script on the EC2 instance through SSM.
command_id=$(aws ssm send-command \
--instance-ids "$INSTANCE_ID" \
--document-name AWS-RunShellScript \
--parameters "commands=$commands,executionTimeout=$EXECUTION_TIMEOUT" \
--query 'Command.CommandId' \
--output text)

# Poll SSM until the remote command finishes, then print its output.
while true; do
status=$(aws ssm get-command-invocation \
--command-id "$command_id" \
--instance-id "$INSTANCE_ID" \
--query 'Status' \
--output text)

case "$status" in
Success)
break
;;
Failed|Cancelled|TimedOut|Cancelling)
aws ssm get-command-invocation --command-id "$command_id" --instance-id "$INSTANCE_ID" --query 'StandardOutputContent' --output text
aws ssm get-command-invocation --command-id "$command_id" --instance-id "$INSTANCE_ID" --query 'StandardErrorContent' --output text
exit 1
;;
Pending|InProgress|Delayed)
sleep 10
;;
esac
done

aws ssm get-command-invocation \
--command-id "$command_id" \
--instance-id "$INSTANCE_ID" \
--query 'StandardOutputContent' \
--output text
70 changes: 0 additions & 70 deletions .github/slack_oncall_reminder.py

This file was deleted.

15 changes: 12 additions & 3 deletions .github/workflows/check-formatting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,24 @@ on:
pull_request:
workflow_call:

permissions:
contents: read

jobs:
check:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871
with:
persist-credentials: false

- name: Run black to check formatting
uses: psf/black@stable
uses: psf/black@87928e6d6761a4a6d22250e1fee5601b3998086e
with:
version: "25.1.0"

- name: Run isort to check import order
uses: isort/isort-action@v1
uses: isort/isort-action@24d8a7a51d33ca7f36c3f23598dafa33f7071326
with:
isort-version: "5.12.0"
30 changes: 0 additions & 30 deletions .github/workflows/on-call-reminder.yml

This file was deleted.

130 changes: 130 additions & 0 deletions .github/workflows/run-benchmarks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,130 @@
name: Run Benchmarks

on:
issue_comment:
types: [created]

jobs:
check-permission:
runs-on: ubuntu-latest
permissions:
contents: none
if: >
github.event.issue.pull_request &&
startsWith(github.event.comment.body, '!benchmark')
steps:
- name: Check user's permission level
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea
with:
script: |
const username = context.payload.comment.user.login;
const { data } = await github.rest.repos.getCollaboratorPermissionLevel({
owner: context.repo.owner,
repo: context.repo.repo,
username: username,
});
const userRole = data.role_name;
const allowedRoles = ["admin", "write", "maintain", "triage"];
console.log(`User ${username} has role: ${userRole}`);
// Fail the job if user doesn't have allowed role
if (!allowedRoles.includes(userRole)) {
throw new Error(`User does not have sufficient permissions to run the benchmarks.`);
}

run-benchmarks:
needs: check-permission
runs-on: ubuntu-latest
permissions:
pull-requests: write
steps:
- name: Benchmarks Started Comment
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea
with:
script: |
const commentId = context.payload.comment.id;
const originalBody = context.payload.comment.body;
// Append a message to indicate benchmarks have started running
const newBody = `${originalBody}\n\n🚀 Benchmarks are running...`;
// Update the comment with the new body text
await github.rest.issues.updateComment({
owner: context.repo.owner,
repo: context.repo.repo,
comment_id: commentId,
body: newBody,
});

- name: Fetch PR Details
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea
with:
script: |
const pr = await github.rest.pulls.get({
owner: context.repo.owner,
repo: context.repo.repo,
pull_number: context.issue.number
});

const body = context.payload.comment.body.trim();
const requestedSha = body.split(/\s+/)[1];

core.exportVariable('BASE_SHA', pr.data.base.sha);
core.exportVariable('COMPARE_SHA', requestedSha);

- name: Print PR Details
run: |
echo "COMPARE_SHA: $COMPARE_SHA"
echo "BASE_SHA: $BASE_SHA"

- name: Checkout base branch
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871
with:
ref: ${{ env.BASE_SHA }}
path: base
persist-credentials: false

- name: Checkout compare branch
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871
with:
ref: ${{ env.COMPARE_SHA }}
path: compare
persist-credentials: false

- name: Set up Python
uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38
with:
python-version: '3.x'

- name: Install pyperf
run: |
python -m pip install --upgrade pip
pip install pyperf

- name: Run benchmark on base branch
working-directory: base
run: python tools/benchmarking/ci/run_benchmarks.py -o ../base.json

- name: Run benchmark on compare branch
working-directory: compare
run: python tools/benchmarking/ci/run_benchmarks.py -o ../head.json

- name: Compare benchmarks results
id: compare
run: |
python -m pyperf compare_to --table --table-format=md -G --min-speed=10 base.json head.json > comparison.txt
echo "Comparison results:"
cat comparison.txt

- name: Post benchmark results
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea
with:
script: |
const fs = require('fs');
const result = fs.readFileSync('comparison.txt', 'utf8');
const commentId = context.payload.comment.id;
const originalBody = context.payload.comment.body;
const newBody = `${originalBody}\n\n🚀 Benchmarks completed.\n\n${result}`;
await github.rest.issues.updateComment({
owner: context.repo.owner,
repo: context.repo.repo,
comment_id: commentId,
body: newBody,
});
19 changes: 12 additions & 7 deletions .github/workflows/run-coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,31 +17,36 @@ on:
description: Git ref on which to run the tests.
type: string

permissions:
contents: read

jobs:
coverage:
strategy:
fail-fast: true
matrix:
python-version: ["3.11"]
python-version: ["3.12"]
os: [ubuntu-latest]
extras: ["test-full"]
runs-on: ${{ matrix.os }}

steps:
- name: Checkout given ref
uses: actions/checkout@v3
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871
if: inputs.ref != ''
with:
ref: ${{ inputs.ref }}
persist-credentials: false

- name: Checkout current branch
uses: actions/checkout@v3
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871
if: inputs.ref == ''
with:
ref: ${{ github.ref }}
persist-credentials: false

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
Expand All @@ -57,9 +62,9 @@ jobs:
- name: Run and report code coverage
run: |
pytest --cov --cov-report json

- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4.0.1
uses: codecov/codecov-action@0565863a31f2c772f9f0395002a31e3f06189574
with:
token: ${{ secrets.CODECOV_TOKEN }}
slug: BerkeleyLearnVerify/Scenic
slug: BerkeleyLearnVerify/Scenic
Loading