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: add publisher program to sync cli #44

Merged
merged 10 commits into from
Sep 9, 2024

Conversation

ali-bahjati
Copy link
Contributor

No description provided.

@@ -100,6 +114,12 @@ async def fetch_minimum_balance(self, size: int) -> int:
async with AsyncClient(self.rpc_endpoint) as client:
return (await client.get_minimum_balance_for_rent_exemption(size)).value

async def account_exists(self, key: PublicKey) -> bool:
Copy link
Contributor

Choose a reason for hiding this comment

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

There is already an account_exists function in util.py (it's being imported and used already in this file too)

@@ -16,6 +16,15 @@
from program_admin import instructions as pyth_program
from program_admin.keys import load_keypair
from program_admin.parsing import parse_account
from program_admin.publisher_program_instructions import (
Copy link
Contributor

Choose a reason for hiding this comment

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

I think if you use a formatter such as black/ruff it will combine these two import declarations.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

actually it seems that the formatter in pre-commit (black i assume) is breaking them apart. idk why but i can't join them.

@ali-bahjati ali-bahjati merged commit 15e39c3 into main Sep 9, 2024
2 checks passed
@ali-bahjati ali-bahjati deleted the add-sync-publisher-program branch September 9, 2024 13:16
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.

4 participants