Skip to content

feat: refactor pyth lazer protocol #2945

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Conversation

keyvankhademi
Copy link
Contributor

Summary

refactor pyth lazer protocol to be more readable and have consistent variable/function names for value, mantissa, and exponent that follows the following formula
value = mantissa * 10^exponent

Rationale

The code was hard to understand

How has this been tested?

  • Current tests cover my changes
  • Added new tests
  • Manually tested the code

ran tests

Copy link

vercel bot commented Aug 11, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Project Deployment Preview Comments Updated (UTC)
entropy-debugger Ready Preview Comment Aug 12, 2025 2:25pm
7 Skipped Deployments
Project Deployment Preview Comments Updated (UTC)
api-reference ⬜️ Skipped Aug 12, 2025 2:25pm
component-library ⬜️ Skipped Aug 12, 2025 2:25pm
developer-hub ⬜️ Skipped Aug 12, 2025 2:25pm
entropy-explorer ⬜️ Skipped Aug 12, 2025 2:25pm
insights ⬜️ Skipped Aug 12, 2025 2:25pm
proposals ⬜️ Skipped Aug 12, 2025 2:25pm
staking ⬜️ Skipped Aug 12, 2025 2:25pm

@@ -7,7 +7,7 @@ license = "Apache-2.0"
repository = "https://github.com/pyth-network/pyth-crosschain"

[dependencies]
pyth-lazer-protocol = { version = "0.11.0", path = "../../sdk/rust/protocol" }
pyth-lazer-protocol = { version = "0.12.0", path = "../../sdk/rust/protocol" }
Copy link
Contributor

Choose a reason for hiding this comment

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

NIT: 0.11.1?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

There is function name change.

@vercel vercel bot temporarily deployed to Preview – api-reference August 12, 2025 14:25 Inactive
@vercel vercel bot temporarily deployed to Preview – developer-hub August 12, 2025 14:25 Inactive
@vercel vercel bot temporarily deployed to Preview – component-library August 12, 2025 14:25 Inactive
@vercel vercel bot temporarily deployed to Preview – insights August 12, 2025 14:25 Inactive
@vercel vercel bot temporarily deployed to Preview – entropy-explorer August 12, 2025 14:25 Inactive
@vercel vercel bot temporarily deployed to Preview – staking August 12, 2025 14:25 Inactive
@vercel vercel bot temporarily deployed to Preview – proposals August 12, 2025 14:25 Inactive
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