Skip to content

feat: new statement store API#62

Closed
Nemanya8 wants to merge 2 commits into
polkadot-api:mainfrom
Nemanya8:main
Closed

feat: new statement store API#62
Nemanya8 wants to merge 2 commits into
polkadot-api:mainfrom
Nemanya8:main

Conversation

@Nemanya8
Copy link
Copy Markdown

No description provided.

Copy link
Copy Markdown
Member

@josepot josepot left a comment

Choose a reason for hiding this comment

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

Thanks for putting this together. I’ve skimmed the PR and I think there are a few significant issues to resolve before it’s ready, primarily around how subscriptions are handled. There are also some secondary issues (including type-level decisions that could result in an inconsistent or less ergonomic API).

One important note on timing: we’ve been operating unfunded for the last two months, so we can’t commit to an urgent review or quickly reacting to upstream changes that weren’t coordinate with us.

We’ll try to take a deeper look next week, but our current focus is on securing sustainable maintenance for the core libraries of PAPI. Because this SDK doesn’t directly or indirectly generate revenue, unpaid work on it is unfortunately at the bottom of our priorities right now.

We also shared a recent maintenance/status update here for expectations.

@josepot josepot requested review from valentunn and removed request for valentunn February 28, 2026 14:14
@voliva
Copy link
Copy Markdown
Contributor

voliva commented Mar 20, 2026

Thanks for the PR, however this one has many issues that led me to solve it in a different PR: #64

  • The subscribe parameter that this implementation requires is not compatible with PAPI client's _subscribe method - It's a different interface.
  • At this level of abstraction, the primitive for subscriptions are Observables. Makes them easier to compose, transform and manage their lifetime.
  • I'm not sure exposing expiry directly is valuable. If the way of interacting with Statements is with timestamp + sequence number, I think it's better to have it decode to those two fields, rather than leaking that parameter and then having to extend the API surface with more methods or utilities to help deal with that.
  • I'd rather keep a smaller API surface for filters. I think it's fine offering some defaults (broadcasts + posted), but sounds like that could be one same API/request that can get filtered differently afterwards.

Please @Nemanya8 take a look at #64 and let me know if I overlooked something. I'm happy to have a call if you think it's needed.

My biggest questions / assumptions I took:

CC @valentunn

@voliva voliva closed this Mar 20, 2026
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