Skip to content

Commit

Permalink
chore: Revert temporary changes
Browse files Browse the repository at this point in the history
  • Loading branch information
pierre-l committed Apr 8, 2024
1 parent ac4391c commit 2eb2c95
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 54 deletions.
38 changes: 1 addition & 37 deletions Cargo.lock

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

8 changes: 2 additions & 6 deletions crates/core/src/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -124,10 +124,6 @@ pub struct BeerusClient {

impl BeerusClient {
pub async fn new(config: &Config) -> Result<Self> {
// TODO Remove
tracing::info!("STARTING {:?}", config);


#[cfg(not(target_arch = "wasm32"))]
let mut helios_client: Client<FileDB> = config.to_helios_client().await;
#[cfg(target_arch = "wasm32")]
Expand All @@ -141,8 +137,8 @@ impl BeerusClient {
.await
.context("failed to fetch syncing status")?
{
info!("{} syncing: head={}", config.network, sync.highest_block);
thread::sleep(time::Duration::from_millis(300));
debug!("{} syncing: head={}", config.network, sync.highest_block);
thread::sleep(time::Duration::from_secs(1));
}

get_starknet_state_root(
Expand Down
5 changes: 1 addition & 4 deletions crates/rpc/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,6 @@ thiserror.workspace = true
tracing.workspace = true

[dev-dependencies]
# TODO Remove
env_logger = "0.11"
serde_json = "1.0"
reqwest = "0.11.13"
tokio = { version = "1", features = ["sync", "macros", "rt", "time"] }
tokio-retry = "0.3"
tokio = { version = "1", features = ["sync", "macros", "rt", "time"] }
10 changes: 3 additions & 7 deletions crates/rpc/tests/rpc.rs
Original file line number Diff line number Diff line change
@@ -1,23 +1,19 @@
// These tests need Beerus to run in the background, hence why they're hidden behing the following feature.
#![cfg(feature = "integration-tests")]

use beerus_core::{client::BeerusClient, config::Config};
use beerus_rpc::BeerusRpc;
use reqwest::Url;
use starknet::{
core::types::{
BlockHashAndNumber, BlockId, BlockTag, BlockWithTxHashes, BlockWithTxs,
DeclareTransaction, DeployAccountTransaction, Event, EventFilter,
FieldElement, InvokeTransaction, MaybePendingBlockWithTxHashes,
BlockId, BlockTag, BlockWithTxHashes, BlockWithTxs, DeclareTransaction,
DeployAccountTransaction, Event, EventFilter, FieldElement,
InvokeTransaction, MaybePendingBlockWithTxHashes,
MaybePendingBlockWithTxs, MaybePendingTransactionReceipt, Transaction,
TransactionReceipt,
},
providers::{
jsonrpc::HttpTransport, JsonRpcClient, Provider, ProviderError,
},
};
use std::{format, sync::Once};
use tokio_retry::Retry;

struct TestContext<T> {
client: JsonRpcClient<HttpTransport>,
Expand Down

0 comments on commit 2eb2c95

Please sign in to comment.