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(eth-bytecode-db): bump verification-common to support non-map 'compilation_artifacts.sources' values #1216

Merged
merged 1 commit into from
Jan 28, 2025
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
2 changes: 1 addition & 1 deletion eth-bytecode-db/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion eth-bytecode-db/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -75,4 +75,4 @@ tonic-build = { version = "0.8" }
tracing = { version = "0.1" }
tracing-subscriber = { version = "0.3" }
url = { version = "2" }
verification-common = { git = "https://github.com/blockscout/blockscout-rs", rev = "5481500" }
verification-common = { git = "https://github.com/blockscout/blockscout-rs", rev = "8d9cf0e" }
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,10 @@ impl DatabaseService {
contract_address.to_vec(),
)
.await
.map_err(|err| tonic::Status::internal(err.to_string()))?
.map_err(|err| {
tracing::error!("error while retrieving alliance sources: {err:#?}");
tonic::Status::internal(err.to_string())
})?
.into_iter()
.map(|source| SourceWrapper::from(source).into_inner())
.collect();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use crate::from_json;
use blockscout_service_launcher::test_database::database;
use std::collections::BTreeMap;
use verification_common::verifier_alliance::{
CompilationArtifacts, CreationCodeArtifacts, RuntimeCodeArtifacts, SourceId,
CompilationArtifacts, CreationCodeArtifacts, RuntimeCodeArtifacts,
};
use verifier_alliance_database::{
internal, CompiledContract, CompiledContractCompiler, CompiledContractLanguage,
Expand Down Expand Up @@ -30,7 +30,7 @@ async fn insert_compiled_contract_works() {
devdoc: Some(from_json!({"devdoc": "value"})),
userdoc: Some(from_json!({"userdoc": "value"})),
storage_layout: Some(from_json!({"storage": "value"})),
sources: Some(BTreeMap::from([("src/Counter.sol".into(), SourceId {id: 0})])),
sources: Some(from_json!({"src/Counter.sol": { "id": 0 }})),
},
creation_code: vec![0x1, 0x2],
creation_code_artifacts: CreationCodeArtifacts {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ use sea_orm::{prelude::Uuid, DatabaseConnection};
use std::collections::BTreeMap;
use verification_common::verifier_alliance::{
CompilationArtifacts, CreationCodeArtifacts, Match, MatchTransformation, MatchValues,
RuntimeCodeArtifacts, SourceId,
RuntimeCodeArtifacts,
};
use verifier_alliance_database::{
CompiledContract, CompiledContractCompiler, CompiledContractLanguage, InsertContractDeployment,
Expand Down Expand Up @@ -191,7 +191,7 @@ fn complete_compiled_contract() -> CompiledContract {
devdoc: Some(from_json!({"devdoc": "value"})),
userdoc: Some(from_json!({"userdoc": "value"})),
storage_layout: Some(from_json!({"storage": "value"})),
sources: Some(BTreeMap::from([("src/Counter.sol".into(), SourceId {id: 0})]))
sources: Some(from_json!({"src/Counter.sol": { "id": 0 }})),
},
creation_code: vec![0x1, 0x2],
creation_code_artifacts: CreationCodeArtifacts {
Expand Down
Loading