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/debug constraints #142

Merged
merged 2 commits into from
Dec 18, 2024
Merged
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
26 changes: 17 additions & 9 deletions proofman/src/constraints.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,12 @@ pub fn verify_constraints_proof<F: Field>(
let air_name = &pctx.global_info.airs[air_instance.airgroup_id][air_instance.air_id].name;
let mut valid_constraints_prover = true;
log::info!(
"{}: ► Instance #{}: Air [{}:{}] {}",
"{}: ► Instance #{} of {} (Airgroup {} - Air {})",
MY_NAME,
air_instance_index,
air_instance.air_instance_id.unwrap(),
air_name,
air_instance.airgroup_id,
air_instance.air_id,
air_name,
);
for constraint in &constraints[air_instance_index] {
let line_str = unsafe { CStr::from_ptr(constraint.line) };
Expand Down Expand Up @@ -104,17 +104,25 @@ pub fn verify_constraints_proof<F: Field>(
log::info!(
"{}: ··· {}",
MY_NAME,
format!("\u{2717} Not all constraints for Instance #{} were verified", air_instance_index,)
.bright_red()
.bold()
format!(
"\u{2717} Not all constraints for Instance #{} of {} were verified",
air_instance.air_instance_id.unwrap(),
air_name
)
.bright_red()
.bold()
);
} else {
log::info!(
"{}: {}",
MY_NAME,
format!("\u{2713} All constraints for Instance #{} were verified", air_instance_index,)
.bright_green()
.bold()
format!(
"\u{2713} All constraints for Instance #{} of {} were verified",
air_instance.air_instance_id.unwrap(),
air_name
)
.bright_green()
.bold()
);
}

Expand Down
Loading