starknet_transaction_prover: add deployment smoke script and guide#14052
starknet_transaction_prover: add deployment smoke script and guide#14052avi-starkware wants to merge 1 commit into
Conversation
|
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
PR SummaryLow Risk Overview The guide documents prerequisites ( The script automates those checks: it reads Reviewed by Cursor Bugbot for commit 649e3c3. Bugbot is set up for automated code reviews on this repo. Configure here. |
5ea83ee to
3457808
Compare
49aebc4 to
0d65f02
Compare
3457808 to
ac2d30f
Compare
0d65f02 to
5f72fc7
Compare
ac2d30f to
cb3ebef
Compare
5f72fc7 to
8161746
Compare
| -d "$(cat "$TMP_DIR/prove_request_valid.json")" > "$TMP_DIR/concurrency_$i.json" | ||
| ) & | ||
| pids+=("$!") | ||
| done |
There was a problem hiding this comment.
Concurrency curl calls lack timeout, risking indefinite hang
Low Severity
The three concurrent curl calls in check_concurrency_and_recovery are the only network calls in the script without a --max-time limit. Every other call goes through rpc_call_prover or rpc_call_chain, both of which set --max-time 30. If the prover is slow or unresponsive, the wait loop blocks indefinitely, which is problematic for a script targeting a 5–10 minute runtime and likely used in CI/CD pipelines.
Reviewed by Cursor Bugbot for commit 8161746. Configure here.
cb3ebef to
93accf4
Compare
8161746 to
e2aec91
Compare
93accf4 to
7a48fbc
Compare
e2aec91 to
649e3c3
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 5 potential issues.
There are 6 total unresolved issues (including 1 from previous review).
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 649e3c3. Configure here.
| # `|| true` keeps the script alive when the prover is unreachable so the EXIT trap still | ||
| # prints PASS/FAIL totals; the check-level code surfaces the empty body via a FAIL entry. | ||
| curl -sS --max-time 30 "$PROVER_URL" -H 'content-type: application/json' -d "$payload" || true | ||
| } |
There was a problem hiding this comment.
Prove requests use thirty second timeout
High Severity
rpc_call_prover applies a 30-second curl limit to every prover call, including starknet_proveTransaction. Real proving often exceeds that window, so the happy-path and recovery checks can fail with empty responses even when the service is healthy.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit 649e3c3. Configure here.
| pass_step "TLS cert valid for $days_left days (≥ $min_days)" | ||
| else | ||
| fail_step "TLS cert expires in $days_left days (< $min_days); notAfter=$not_after" | ||
| fi |
There was a problem hiding this comment.
TLS expiry parsing needs GNU date
Medium Severity
check_tls_certificate parses OpenSSL’s notAfter with date -d, which is GNU-specific. On macOS or BSD, parsing fails, expiry_epoch becomes 0, and valid certificates are reported as expiring immediately.
Reviewed by Cursor Bugbot for commit 649e3c3. Configure here.
|
|
||
| tx_hash=$(rpc_call_chain "{\"jsonrpc\":\"2.0\",\"id\":101,\"method\":\"starknet_getBlockWithTxs\",\"params\":[{\"block_number\":$block_number}]}" \ | ||
| | jq -r --arg tx_type "$tx_type" --arg tx_version "$tx_version" \ | ||
| '[.result.transactions[] | select(.type==$tx_type and .version==$tx_version) | .transaction_hash] | .[0] // empty') |
There was a problem hiding this comment.
Block scan aborts on RPC errors
Medium Severity
With set -o pipefail, a failed jq filter on a bad starknet_getBlockWithTxs response aborts find_tx_hash instead of skipping that block. The whole script can exit before the PASS/FAIL summary when the chain RPC returns errors for some heights.
Reviewed by Cursor Bugbot for commit 649e3c3. Configure here.
| fi | ||
| if ! command -v openssl >/dev/null 2>&1; then | ||
| fail_step "TLS cert check skipped — openssl not installed on this host" | ||
| return 0 |
There was a problem hiding this comment.
OpenSSL missing still marks failure
Low Severity
When PROVER_URL is HTTPS and openssl is missing, the script calls fail_step with a “skipped” message but still returns without treating the check as optional, so FAIL_COUNT rises and the deployment gate fails.
Reviewed by Cursor Bugbot for commit 649e3c3. Configure here.
| fail_step "/ohttp-keys response missing cache-control header" | ||
| return 0 | ||
| fi | ||
| pass_step "/ohttp-keys returns non-empty, cacheable key material" |
There was a problem hiding this comment.
OHTTP omits non-zero max-age
Low Severity
check_ohttp_keys only requires a cache-control header, while the smoke guide requires a non-zero max-age. Responses like Cache-Control: no-cache can pass the script but fail the documented deployment criteria.
Reviewed by Cursor Bugbot for commit 649e3c3. Configure here.



Adds three operational artifacts:
MANUAL_TESTING_GUIDE.md — comprehensive manual testing reference
(endpoints, negative flows, CORS matrix, compression, concurrency,
load) for deep deployment validation.
DEPLOYMENT_SMOKE_TESTING_GUIDE.md — per-deploy 5-10 minute checklist
covering reachability, core JSON-RPC methods, one real proving flow,
invalid-request handling, and concurrency protection.
deployment_smoke.sh — automated smoke script that mirrors the smoke
guide's checks, prints a PASS/FAIL summary, and supports
KEEP_ARTIFACTS / TX_HASH / LOOKBACK_BLOCKS overrides for debugging.