-
Notifications
You must be signed in to change notification settings - Fork 626
upgrade 0809: use feynman guest rkyv #1718
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -83,7 +83,7 @@ impl TryFrom<BundleProvingTask> for ProvingTask { | |
| .into_iter() | ||
| .map(|w_proof| w_proof.proof.into_root_proof().expect("expect root proof")) | ||
| .collect(), | ||
| serialized_witness: vec![witness.rkyv_serialize(None)?.to_vec()], | ||
| serialized_witness: vec![witness.rkyv_serialize(Some(ForkName::Feynman))?.to_vec()], | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 💡 Verification agent 🧩 Analysis chainHard-coding Feynman here ignores the task’s provided fork_name; use the actual fork to avoid mismatches Serialization should respect the task’s fork to keep witness and metadata consistent. Hard-coding Apply this diff within the selected line: - serialized_witness: vec![witness.rkyv_serialize(Some(ForkName::Feynman))?.to_vec()],
+ serialized_witness: vec![witness.rkyv_serialize(Some(fork))?.to_vec()],And add this line before constructing let fork = ForkName::from(value.fork_name.as_str());Optional repo-wide sanity check: 🏁 Script executed: #!/bin/bash
set -euo pipefail
echo "Calls to rkyv_serialize and their fork arg:"
rg --line-number 'rkyv_serialize\(' -A 1
echo
echo "Places using Some(ForkName::Feynman):"
rg --line-number 'Some\(ForkName::Feynman\)'
echo
echo "Places constructing ForkName dynamically:"
rg --line-number 'ForkName::from\('Length of output: 1308 Replace hard-coded Serialization must use the configured fork to keep witness and metadata in sync. Update both occurrences where Files needing changes:
Apply this diff in each file: - serialized_witness: vec![witness.rkyv_serialize(Some(ForkName::Feynman))?.to_vec()],
+ serialized_witness: vec![witness.rkyv_serialize(Some(fork_name))?.to_vec()],Both modules already bind Optional sanity check to confirm all instances: rg --line-number 'rkyv_serialize\(' -A 1
rg --line-number 'Some\(ForkName::Feynman\)'
rg --line-number 'ForkName::from\('🤖 Prompt for AI Agents |
||
| vk: Vec::new(), | ||
| }) | ||
| } | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -3,6 +3,7 @@ use eyre::Result; | |
| use sbv_primitives::{types::BlockWitness, B256}; | ||
| use scroll_zkvm_types::{ | ||
| chunk::{execute, ChunkInfo, ChunkWitness, ToArchievedWitness}, | ||
| public_inputs::ForkName, | ||
| task::ProvingTask, | ||
| }; | ||
|
|
||
|
|
@@ -71,7 +72,7 @@ impl TryFrom<ChunkProvingTask> for ProvingTask { | |
| identifier: value.identifier(), | ||
| fork_name: value.fork_name, | ||
| aggregated_proofs: Vec::new(), | ||
| serialized_witness: vec![witness.rkyv_serialize(None)?.to_vec()], | ||
| serialized_witness: vec![witness.rkyv_serialize(Some(ForkName::Feynman))?.to_vec()], | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 💡 Verification agent 🧩 Analysis chainSame issue: serialization must use the task’s fork, not a hard-coded Feynman Align serialization with the provided Apply this diff within the selected line: - serialized_witness: vec![witness.rkyv_serialize(Some(ForkName::Feynman))?.to_vec()],
+ serialized_witness: vec![witness.rkyv_serialize(Some(fork))?.to_vec()],And add this line before constructing let fork = ForkName::from(value.fork_name.as_str());Optional check for consistency across the repo: 🏁 Script executed: #!/bin/bash
set -euo pipefail
echo "All rkyv_serialize calls and fork argument:"
rg --line-number 'rkyv_serialize\(' -A 1Length of output: 558 Use the provided fork name for serialization instead of hard-coding Feynman Both • Extract the fork from Locations to update:
Example diff for both files: @@ before constructing the ProvingTask
- serialized_witness: vec![witness.rkyv_serialize(Some(ForkName::Feynman))?.to_vec()],
+ serialized_witness: vec![witness.rkyv_serialize(Some(fork))?.to_vec()],Make sure you add, just above the task construction in each file: let fork = ForkName::from(value.fork_name.as_str());This ensures serialization always uses the fork specified by the caller. 🤖 Prompt for AI Agents |
||
| vk: Vec::new(), | ||
| }) | ||
| } | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Verification agent
🧩 Analysis chain
Pin git dependencies to the exact commit for reproducibility and supply-chain safety
Using a tag is better than a branch, but tags can be retagged. Since the PR references commit 72f9abb00f0ef7c5e46b7856d58bb86cbb332509, prefer
revto guarantee determinism.Apply this diff:
Verification script to confirm the tag’s commit (optional):
🏁 Script executed:
Length of output: 658
Pin git dependencies to an exact commit using
revConfirmed that tag
0.5.4currently points to commit72f9abb00f0ef7c5e46b7856d58bb86cbb332509. To guard against future retagging and ensure full reproducibility, switch fromtagtorev.• Update in
Cargo.toml(around lines 20–22):📝 Committable suggestion
🤖 Prompt for AI Agents