Skip to content

Commit

Permalink
feat(snos_job): Filled internal_id
Browse files Browse the repository at this point in the history
  • Loading branch information
akhercha committed Jul 22, 2024
1 parent 5ade4f7 commit 8d2a124
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions crates/orchestrator/src/jobs/snos_job/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -70,14 +70,14 @@ impl Job for SnosJob {
// Currently not possible because of dependencies versions conflicts between
// SNOS, cairo-vm and madara.
let mut state = DummyState {};
let (block_info, chain_info) = self.build_info(config, &block_number, &snos_input).await?;
let block_number_and_hash = BlockNumberHashPair {
number: block_number,
hash: BlockHash(StarkFelt::from(
FieldElement::from_bytes_be(&snos_input.block_hash.clone().to_bytes_be())
.expect("Could not convert Felt to FieldElement"),
)),
};
let (block_info, chain_info) = self.build_info(config, &block_number, &snos_input).await?;

let block_context = match pre_process_block(
&mut state,
Expand Down Expand Up @@ -111,11 +111,10 @@ impl Job for SnosJob {
Err(e) => return Err(eyre!("Could not run SNOS for block #{}: {}", block_number, e)),
};

// 3. Store the received PIE in DB
// 3. Store the received outputs in our cloud storage
self.store_into_cloud_storage(config, &block_number, cairo_pie, snos_output).await?;

// TODO: which internal id do we want?
Ok("some_create_id?".into())
Ok(format!("snos_{block_number}"))
}

async fn verify_job(&self, _config: &Config, _job: &mut JobItem) -> Result<JobVerificationStatus> {
Expand Down

0 comments on commit 8d2a124

Please sign in to comment.