-
Couldn't load subscription status.
- Fork 29.7k
Description
Link to the code that reproduces this issue
https://github.com/mordechaim/vercel-revalidate
To Reproduce
- Navigate to the deployment on https://vercel-revalidate-three.vercel.app/
- Check the date, it should be the date of the last time someone pressed the "Revalidate" button
- Press once: The date properly updates
- Press again: nothing happens
Another issue I noticed with this reproduction: Refreshing the page will show the old data until a 2nd refresh is done.
Current vs. Expected behavior
unstable_cache serves stale data when revalidating more than once in a short period.
When running next build && next start and trying locally, everything works flawlessly.
The expected behavior is to always show the latest date.
The other issue is that even when the router cache does update (after a single revalidation), refreshing will show stale data until a second refresh is done.
I'm not sure if the 2nd issue is related or if I should open another issue.
Verify canary release
- I verified that the issue exists in the latest Next.js canary release
Provide environment information
Operating System:
Platform: win32
Arch: x64
Version: Windows 10 Home
Binaries:
Node: 20.5.0
npm: N/A
Yarn: N/A
pnpm: N/A
Relevant Packages:
next: 14.0.5-canary.58
eslint-config-next: 14.0.4
react: 18.2.0
react-dom: 18.2.0
typescript: 5.3.3
Next.js Config:
output: N/AWhich area(s) are affected? (Select all that apply)
App Router
Which stage(s) are affected? (Select all that apply)
Vercel (Deployed)
Additional context
No response