Skip to content

📝 [RUM-16097] Add migration skills for v4→v5 and v5→v6 SDK upgrades#4640

Open
mormubis wants to merge 39 commits into
mainfrom
adlrb/migration-skills-v4-v5-v5-v6
Open

📝 [RUM-16097] Add migration skills for v4→v5 and v5→v6 SDK upgrades#4640
mormubis wants to merge 39 commits into
mainfrom
adlrb/migration-skills-v4-v5-v5-v6

Conversation

@mormubis

Copy link
Copy Markdown
Contributor

Motivation

Benoit shipped the v6→v7 migration skill in #4486. We need equivalent skills for v4→v5 and v5→v6 so they can serve as the single source of truth for migration guides and feed the hidden_prompt sent to code-gen-api.

Changes

Two new skill files following the same structure as the existing v6→v7 skill. Content sourced from the official upgrade guide and the CHANGELOG, then cross-referenced to make sure nothing was missed.

Test instructions

These are markdown files consumed by AI coding assistants. No runtime behavior to test.

Checklist

  • Tested locally
  • Tested on staging
  • Added unit tests for this change.
  • Added e2e/integration tests for this change.
  • Updated documentation and/or relevant AGENTS.md file

@mormubis mormubis force-pushed the adlrb/migration-skills-v4-v5-v5-v6 branch from 0ace371 to 760725f Compare May 18, 2026 14:51
@cit-pr-commenter-54b7da

cit-pr-commenter-54b7da Bot commented May 18, 2026

Copy link
Copy Markdown

Bundles Sizes Evolution

📦 Bundle Name Base Size Local Size 𝚫 𝚫% Status
Rum 172.46 KiB 172.46 KiB 0 B 0.00%
Rum Profiler 8.22 KiB 8.22 KiB 0 B 0.00%
Rum Recorder 21.09 KiB 21.09 KiB 0 B 0.00%
Logs 54.47 KiB 54.47 KiB 0 B 0.00%
Rum Slim 129.97 KiB 129.97 KiB 0 B 0.00%
Worker 22.96 KiB 22.96 KiB 0 B 0.00%

@datadog-datadog-prod-us1-2

datadog-datadog-prod-us1-2 Bot commented May 18, 2026

Copy link
Copy Markdown

Tests

🎉 All green!

🧪 All tests passed
❄️ No new flaky tests detected

🎯 Code Coverage (details)
Patch Coverage: 100.00%
Overall Coverage: 76.87% (+0.00%)

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 32c0733 | Docs | Datadog PR Page | Give us feedback!

@mormubis mormubis marked this pull request as ready for review May 20, 2026 10:15
@mormubis mormubis requested a review from a team as a code owner May 20, 2026 10:15

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 760725f96a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .claude/skills/upgrade-browser-sdk-v6/SKILL.md Outdated
@mormubis mormubis force-pushed the adlrb/migration-skills-v4-v5-v5-v6 branch from a9cdc3e to 7d3ae15 Compare May 21, 2026 16:59

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: af32d7c51a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: cafcecc76c

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 05c9f32d0f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9c5bb4d287

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v6/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated
@mormubis mormubis force-pushed the adlrb/migration-skills-v4-v5-v5-v6 branch from 9c5bb4d to 0717e90 Compare June 19, 2026 09:02

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 0d9bc30a8e

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2bd41c7f08

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated
@mormubis mormubis force-pushed the adlrb/migration-skills-v4-v5-v5-v6 branch from 2e73616 to 7dffd20 Compare June 19, 2026 14:46

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 7dffd20264

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v6/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md
Comment thread .claude/skills/upgrade-browser-sdk-v6/SKILL.md

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: e4fc08a9a3

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v6/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v6/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Search: `grep -r "@datadog/browser-" package.json`

P2 Badge Search nested manifests during v7 upgrades

Checked grep --help: operands after the pattern are the files/directories being searched, so grep -r "@datadog/browser-" package.json only inspects the root package.json file. In a workspace where the Browser SDK dependency lives in packages/app/package.json, the v7 migration can leave that package on v6 while only root manifests are updated, resulting in mixed SDK majors; point the command at . with --include='package.json'.


Search: `grep -rn "datadoghq-browser-agent" --include="*.html" --include="*.js" --include="*.ts"`

P2 Badge Include JSX/TSX CDN scripts in crossorigin audit

Checked grep --help: --include=GLOB searches only files matching the listed globs, and this audit omits *.jsx/*.tsx even though Step 1 can update CDN URLs in those files. A React/Next component or dynamic loader that renders the Datadog <script> can be migrated to /v7/ without adding crossorigin, leaving v7 CDN dynamic imports blocked on replay/profiler chunks; use the same code extensions as the URL search.


| `allowFallbackToLocalStorage` | Replace with `sessionPersistence: ['cookie', 'local-storage']` |

P2 Badge Preserve explicit no-local-storage configs

For v6 configs that explicitly set allowFallbackToLocalStorage: false, applying this blanket replacement turns the fallback on: v7's sessionPersistence array tries each entry in order, while the default with no option remains cookie-only (packages/browser-core/src/domain/session/sessionStore.ts:18-41). The migration should say to use ['cookie', 'local-storage'] only when the removed option was true, and to delete explicit false entries, otherwise projects that intentionally avoided localStorage can start persisting sessions there.


- Add `crossorigin` to script-src.

P2 Badge Move crossorigin out of CSP instructions

For CDN migrations, crossorigin is an HTML attribute or script property, not a CSP script-src directive. If someone follows this infrastructure checklist by editing only the CSP policy while missing the Step 2 tag/property change, the v7 SDK still loads without the required CORS mode and its ESM async chunks can fail; reword this bullet to point back to adding crossorigin="anonymous" on the CDN script tags or .crossOrigin on dynamic scripts.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 1ee7d5dfff

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md Outdated
Comment thread .claude/skills/upgrade-browser-sdk-v6/SKILL.md Outdated

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

| `allowFallbackToLocalStorage` | Replace with `sessionPersistence: ['cookie', 'local-storage']` |

P2 Badge Preserve explicit local-storage fallback opt-outs

For v6 configs that explicitly set allowFallbackToLocalStorage: false, applying this replacement enables the fallback they opted out of: v7 treats sessionPersistence: ['cookie', 'local-storage'] as an ordered fallback list, so when cookies are unavailable it will start persisting sessions in localStorage. The migration should only use this replacement for allowFallbackToLocalStorage: true; false configs should delete the option or keep cookie-only persistence.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 8ba9a0cd27

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .claude/skills/upgrade-browser-sdk-v7/SKILL.md
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md
Comment thread .claude/skills/upgrade-browser-sdk-v6/SKILL.md
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md
Comment thread .claude/skills/upgrade-browser-sdk-v5/SKILL.md
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