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/arbiter provider #280

Merged
merged 3 commits into from
Jan 9, 2024
Merged

Feat/arbiter provider #280

merged 3 commits into from
Jan 9, 2024

Conversation

Alexangelj
Copy link
Contributor

@Alexangelj Alexangelj commented Jan 8, 2024

  • Adds a new current field to the model for the currently connected network chain id.
  • Adds the method connect_to_network to the model, for setting the current field based on the chain_id of the client in the argument.
  • Edits the portfolio field to be networks, which is a hashmap of chain ids to their respective data models.
  • Updates all the functions to only update or fetch from the current model, if it's not None.

Closes #229

&mut self,
client: Arc<M>,
) -> anyhow::Result<()> {
let chain_id = client.get_chainid().await?;
Copy link
Contributor

Choose a reason for hiding this comment

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

What is the arbiter Chain Id? We might have it set to 1 right now which will cause collisions with main-net here. We should double check and if it is 1 we should change it so this doesn't happen. What chain Id does anvil support?

@0xJepsen
Copy link
Contributor

0xJepsen commented Jan 9, 2024

Overall i think this approach is really good. We should be careful about what chain ID is used in simulations. We can certainly configure it to what we want but i don't think we configure it at all right now, I'm sure it would be a quick fix in arbiter though.

@0xJepsen 0xJepsen marked this pull request as ready for review January 9, 2024 16:06
@0xJepsen 0xJepsen merged commit 6e89767 into main Jan 9, 2024
5 checks passed
@clemlak clemlak deleted the feat/arbiter-provider branch January 23, 2024 06:10
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.

Getting the arbiter provider in the UI
2 participants