Skip to content

fix(paginator): spec-compliant links typespec - #481

Open
grzuy wants to merge 1 commit into
beam-community:mainfrom
pdqcom:paginator-links-typespec
Open

grzuy wants to merge 1 commit into
beam-community:mainfrom
pdqcom:paginator-links-typespec

Conversation

@grzuy

@grzuy grzuy commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

Hi there,

Seems that per the spec, pagination links can be omitted
https://jsonapi.org/format/#fetching-pagination

Keys MUST either be omitted or have a null value to indicate that a particular link is unavailable.

There seems to be no reason to be so strict about the returned links by paginate callback?
Because of this we have a failing dialyzer check.

Thank you

Per the spec, pagination links can be omitted
https://jsonapi.org/format/#fetching-pagination

> Keys MUST either be omitted or have a null value to indicate that a particular link is unavailable.
@grzuy
grzuy requested a review from a team as a code owner November 6, 2026 16:55
@mattpolzin

Copy link
Copy Markdown
Member

Can you add a new test next to existing pagination tests that uses a new test paginator that returns some but not all links to make sure we aren't making any assumptions about any of the link keys anywhere?

Ideally the new test code would loop over each link key and omit them one at a time via macro (effectively one test per link key without taking up so much space).

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