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

Feat/ag 202 #253

Closed
wants to merge 116 commits into from
Closed

Feat/ag 202 #253

wants to merge 116 commits into from

Conversation

Will-Smith11
Copy link
Collaborator

No description provided.

@Will-Smith11 Will-Smith11 marked this pull request as ready for review November 14, 2024 19:51
Copy link
Collaborator Author

@Will-Smith11 Will-Smith11 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Joe this isn't a frat house. we need to keep the codebase CLEEEEAAN. Pls go through and delete unused / commented out code. If something is commented out because you are going to do work on it in the future. create a branch with the code off this branch, then delete it from this branch pls.

Comment on lines +150 to +151
inner: Arc<Mutex<T>>,
lock: Arc<AtomicBool>,
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

u can just use a unsafe cell instead of doing this

Comment on lines 61 to 83
// tracing::debug!("deploying contracts to anvil");
// let uni_env = UniswapEnv::with_anvil(state_provider.provider()).await?;
// let angstrom_env = AngstromEnv::new(uni_env).await?;
// let rewards_env =
// MockRewardEnv::with_anvil(state_provider.provider()).await?;

// let sqrt_price_x96 =
// SqrtPriceX96::from(get_sqrt_ratio_at_tick(100020).unwrap());
// let tick_spacing = I24::unchecked_from(60);
// let pool_fee = U24::ZERO;
// let snapshot = PoolSnapshot::new(
// vec![LiqRange::new(99900, 100140,
// 5_000_000_000_000_000_000_000_u128).unwrap()], sqrt_price_x96
// )?;
// let pool_key = rewards_env
// .create_pool_and_tokens_from_snapshot(tick_spacing, pool_fee, snapshot)
// .await?;

// tracing::info!("deployed contracts to anvil");

// let angstrom_addr = angstrom_env.angstrom();
// let pools = vec![pool_key];
let pools = vec![];
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

brother ew

Comment on lines +28 to +29
#[clap(long, requires = "fork_block")]
pub fork_url: Option<String>,
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we just set the default to whatever our reth is. Makes it 100 times easier on startup

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we don't necessarily need a fork url for the devnet, but otherwise i agree

bin/devnet/src/main.rs Outdated Show resolved Hide resolved
Comment on lines +1 to +28
// //! CLI definition and entrypoint to executable
// use std::{collections::HashSet, path::PathBuf, sync::Arc};

// use alloy::network::{EthereumWallet, Network};
// use angstrom_metrics::{initialize_prometheus_metrics, METRICS_ENABLED};
// use angstrom_network::manager::StromConsensusEvent;
// use angstrom_types::{primitive::PoolId as AngstromPoolId,
// reth_db_wrapper::RethDbWrapper};
// use order_pool::{order_storage::OrderStorage, PoolConfig, PoolManagerUpdate};
// use reth_node_builder::{FullNode, NodeHandle};
// use secp256k1::{PublicKey, Secp256k1, SecretKey};
// use tokio::sync::mpsc::{
// channel, unbounded_channel, Receiver, Sender, UnboundedReceiver,
// UnboundedSender };
// use validation::order::state::token_pricing::TokenPriceGenerator;

// mod network_builder;
// use alloy::{
// eips::{BlockId, BlockNumberOrTag},
// providers::{network::Ethereum, Provider, ProviderBuilder},
// signers::{k256::ecdsa::SigningKey, local::LocalSigner},
// transports::Transport
// };
// use alloy_chains::Chain;
// use alloy_primitives::{private::serde::Deserialize, Address, BlockNumber};
// use angstrom_eth::{
// handle::{Eth, EthCommand},
// manager::EthDataCleanser
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sloppy. Just delete the entire file

}

impl AngstromTestnetNodeInternals {
pub async fn new(
testnet_node_id: u64,
strom_handles: StromHandles,
strom_network_handle: StromNetworkHandle,
secret_key: SecretKey,
_secret_key: SecretKey,
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if its not used, delete it

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's going to be, i commented out a part of the consensus that uses it

config: AngstromTestnetConfig,
initial_validators: Vec<AngstromValidator>
) -> eyre::Result<Self> {
_initial_validators: Vec<AngstromValidator>,
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if its not used, delete it

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's going to be, i commented out a part of the consensus that uses it

testing-tools/src/types/hooks.rs Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants