Skip to content

Conversation

bplatak
Copy link
Contributor

@bplatak bplatak commented Jul 7, 2025

Summary

Add a new schema for the JRPC endpoint in pyth-lazer-agent for sending updates, and retrieving metadata via the JRPC endpoint. Also move the Timestamp logic to protocol to reuse across pyth-lazer

Rationale

Adding a new endpoint for publishers to communicate with the pyth-lazer-agent.

How has this been tested?

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

Copy link

vercel bot commented Jul 7, 2025

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

8 Skipped Deployments
Name Status Preview Comments Updated (UTC)
api-reference ⬜️ Skipped (Inspect) Jul 9, 2025 5:16pm
component-library ⬜️ Skipped (Inspect) Jul 9, 2025 5:16pm
developer-hub ⬜️ Skipped (Inspect) Jul 9, 2025 5:16pm
entropy-debugger ⬜️ Skipped (Inspect) Jul 9, 2025 5:16pm
entropy-explorer ⬜️ Skipped (Inspect) Jul 9, 2025 5:16pm
insights ⬜️ Skipped (Inspect) Jul 9, 2025 5:16pm
proposals ⬜️ Skipped (Inspect) Jul 9, 2025 5:16pm
staking ⬜️ Skipped (Inspect) Jul 9, 2025 5:16pm

}

#[derive(Serialize, Deserialize)]
struct SymbolMetadata {
Copy link
Collaborator

Choose a reason for hiding this comment

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

let's aim for a map <str -> str> for metadata. i think anything that is usable in the code should not live in metadata (like exponent) but that's a step in the future.

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 BTreeMap<String, serde_value::Value> would be even better. We should support typed metadata instead of converting everything to string. I also agree about separating exponent, etc from arbitrary metadata.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

separating exponent, etc

Which fields do you consider to not be a part of the arbitrary metadata?

@bplatak bplatak force-pushed the feat/pyth-lazer/agent/jrpc-schema-1 branch from da25fcd to 28e1346 Compare July 9, 2025 17:16
@vercel vercel bot temporarily deployed to Preview – component-library July 9, 2025 17:16 Inactive
@vercel vercel bot temporarily deployed to Preview – entropy-explorer July 9, 2025 17:16 Inactive
@vercel vercel bot temporarily deployed to Preview – entropy-debugger July 9, 2025 17:16 Inactive
@vercel vercel bot temporarily deployed to Preview – api-reference July 9, 2025 17:16 Inactive
@vercel vercel bot temporarily deployed to Preview – developer-hub July 9, 2025 17:16 Inactive
@vercel vercel bot temporarily deployed to Preview – insights July 9, 2025 17:16 Inactive
@vercel vercel bot temporarily deployed to Preview – staking July 9, 2025 17:16 Inactive
@vercel vercel bot temporarily deployed to Preview – proposals July 9, 2025 17:16 Inactive
@bplatak bplatak enabled auto-merge (squash) July 9, 2025 17:33
@bplatak bplatak merged commit 01880f7 into main Jul 9, 2025
10 of 11 checks passed
@bplatak bplatak deleted the feat/pyth-lazer/agent/jrpc-schema-1 branch July 9, 2025 17:35
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.

6 participants