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

fix(zkstack_cli): Fix contract verifier init rate limit #3034

Merged
merged 10 commits into from
Oct 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
1 change: 1 addition & 0 deletions .github/workflows/ci-core-reusable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,7 @@ jobs:
echo "SCCACHE_GCS_SERVICE_ACCOUNT=gha-ci-runners@matterlabs-infra.iam.gserviceaccount.com" >> .env
echo "SCCACHE_GCS_RW_MODE=READ_WRITE" >> .env
echo "RUSTC_WRAPPER=sccache" >> .env
echo "GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}" >> .env
echo RUN_CONTRACT_VERIFICATION_TEST=true >> $GITHUB_ENV

- name: Start services
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,13 +79,19 @@ fn get_releases(shell: &Shell, repo: &str, arch: Arch) -> anyhow::Result<Vec<Ver
return get_solc_releases(shell, arch);
}

let response: std::process::Output = Cmd::new(cmd!(
let mut cmd = cmd!(
shell,
"curl https://api.github.com/repos/{repo}/releases"
))
.run_with_output()?;
"curl -f https://api.github.com/repos/{repo}/releases"
);

if let Ok(token) = shell.var("GITHUB_TOKEN") {
cmd = cmd.args(vec![
"-H".to_string(),
format!("Authorization: Bearer {}", token),
]);
}

let response = String::from_utf8(response.stdout)?;
let response = String::from_utf8(Cmd::new(cmd).run_with_output()?.stdout)?;
let releases: Vec<GitHubRelease> = serde_json::from_str(&response)?;

let mut versions = vec![];
Expand Down
Loading