Skip to content

fix(docs): preserve negotiated response cache headers - #9043

Merged
waleedlatif1 merged 2 commits into
stagingfrom
codex/docs-negotiation-cache-fix
Oct 14, 2026
Merged

waleedlatif1 merged 2 commits into
stagingfrom
codex/docs-negotiation-cache-fix

Conversation

@waleedlatif1

@waleedlatif1 waleedlatif1 commented Oct 14, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Preserve application Vary fields when Next's Node response pipeline adds router dimensions, so HTML and Markdown at one docs URL remain distinct cache variants.
  • Pin the small CommonJS/ESM framework patch, preserve native validation and cookie behavior, and retain production HTTP and native edge-case checks in path-scoped CI.

Type of Change

  • Bug fix

Testing

Root lint, all 26 workspace type checks, all 60 audits, the block-registry check, and actionlint pass. Production build and 12 HTTP checks pass. The production regression fails on unpatched HTML and passes with the fix. The retained native suite passes 16 checks across both entry points; removing merging causes eight expected failures, and removing validation causes four. CI runs the full existing suites and uploads both docs HTTP reports.

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing (new tests pass the test-audit authoring gate)
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

@waleedlatif1
waleedlatif1 requested a review from a team as a code owner October 14, 2026 21:50
@vercel

vercel Bot commented Oct 14, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
docs Ready Ready Preview Oct 14, 2026 10:21pm UTC

Request Review

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

No issues found across 7 files

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Turn on auto-fix | Re-trigger cubic

@greptile-apps

greptile-apps Bot commented Oct 14, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[High impact] The PR appears safe to merge; no actionable new issue was found.

Summary

Preserves application Vary fields when Next adds its router fields.

  • Docs responses keep Accept alongside Next.js router cache fields.

The review used the full PR diff because the previous-review history checks did not pass. Tests were not run during this review.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A["Application sets Vary: Accept"] --> B["Next adds router Vary fields"]
  B --> C["Check incoming header value"]
  C --> D["Combine existing and incoming fields"]
  D --> E["Remove case-insensitive duplicates"]
  E --> F["Send combined Vary header"]
Loading

Reviews (2) · Last reviewed commit: "fix(docs): retain native header regressi..." · Reviewed by Greptile

Comment thread apps/docs/scripts/test-negotiation-e2e.ts
@waleedlatif1
waleedlatif1 force-pushed the codex/docs-negotiation-cache-fix branch from 6dc6c53 to 88f5ac0 Compare October 14, 2026 22:15
@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@greptile

@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 14, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@waleedlatif1 I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

No issues found across 8 files

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Turn on auto-fix | Re-trigger cubic

@waleedlatif1
waleedlatif1 merged commit 7589537 into staging Oct 14, 2026
50 of 52 checks passed
@waleedlatif1
waleedlatif1 deleted the codex/docs-negotiation-cache-fix branch October 14, 2026 22:21

This branch was successfully deployed

1 active deployment
Preview — 88f5ac09 Deployed Oct 14, 2026 by vercel[bot]
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.

1 participant