"published" version status serves stale data #1175
Labels
pending-author
[Issue] Awaiting further information or action from the issue author
pending-triage
[Issue] Ticket is pending to be prioritised
Describe the issue you're facing
When setting the
version
key ofISbStoryParams
explicitly to"published"
, the SDK caches responses from some paths and only returns those, even if new data has been published.When
version
is not set (and so is published-only implicitly) this issue does not occur and live published data is accessible immediately.Reproduction
https://stackblitz.com/edit/stackblitz-starters-gwo9au?file=pages%2F%5B%5B...slug%5D%5D.tsx
Steps to reproduce
Put some code like the following in your
getStaticPaths()
, with fallback asblocking
and reasonably shortrevalidate
:pageData
always seems to return up to date data, however,navigationData
only returns the data that was published and live at build time.If the
version
key is removed fromsbParams
, thenavigationData
is always up to date. Similarly,version
set to"draft"
also remains up to date with correct draft/unpublished data.System Info
Used Package Manager
yarn
Error logs (Optional)
No response
Validations
The text was updated successfully, but these errors were encountered: