Skip to content

fix(influxdb3): backfill missing product URLs in localStorage#6961

Merged
jstirnaman merged 2 commits intomasterfrom
claude/fix-issue-6960-sepRP
Mar 18, 2026
Merged

fix(influxdb3): backfill missing product URLs in localStorage#6961
jstirnaman merged 2 commits intomasterfrom
claude/fix-issue-6960-sepRP

Conversation

@jstirnaman
Copy link
Copy Markdown
Contributor

Returning visitors with stale localStorage (created before core/enterprise
products were added) had undefined URL values for new products. The
updateUrls() function then replaced Hugo-rendered hostnames like
localhost:8181 with the string "undefined" in api-endpoint blocks.

Fix by merging DEFAULT_STORAGE_URLS as fallbacks when reading from
localStorage, so new product keys are always present.

closes #6960

https://claude.ai/code/session_01GJZ2yMR5DBk1feqTD5LeHW

Returning visitors with stale localStorage (created before core/enterprise
products were added) had undefined URL values for new products. The
updateUrls() function then replaced Hugo-rendered hostnames like
localhost:8181 with the string "undefined" in api-endpoint blocks.

Fix by merging DEFAULT_STORAGE_URLS as fallbacks when reading from
localStorage, so new product keys are always present.

closes #6960

https://claude.ai/code/session_01GJZ2yMR5DBk1feqTD5LeHW
@jstirnaman jstirnaman requested a review from a team as a code owner March 18, 2026 04:19
@jstirnaman jstirnaman requested review from Copilot and sanderson and removed request for a team March 18, 2026 04:19
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Fixes an issue where returning visitors with older localStorage URL objects (created before new InfluxDB 3 products were added) could end up with missing product keys, which then propagated undefined into URL replacement logic (notably in API endpoint blocks).

Changes:

  • Backfill missing product URL keys by merging DEFAULT_STORAGE_URLS with stored URL data when reading all URLs.
  • Add a default fallback when reading a single product URL from storage.

You can also share your feedback on Copilot code review. Take the survey.

Adds 2 E2E tests for the fix in #6960:

1. Stale localStorage (missing `core` key) should not cause "undefined"
   to appear in api-endpoint or code blocks on the plugins page.
2. Fresh localStorage should be initialized with all expected product
   URL keys (oss, cloud, core, enterprise, serverless, dedicated, clustered).

Run with:
  node cypress/support/run-e2e-specs.js --spec "cypress/e2e/influxdb-url.cy.js" --no-mapping

https://claude.ai/code/session_01GJZ2yMR5DBk1feqTD5LeHW
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Fixes a regression where returning visitors with stale localStorage (missing newly added product URL keys like core/enterprise) could cause InfluxDB URL replacement to substitute rendered hosts with the literal string "undefined" in api-endpoint blocks.

Changes:

  • Merge DEFAULT_STORAGE_URLS into stored URL data when reading from localStorage, ensuring newly introduced product keys always have fallback values.
  • Add Cypress E2E regression tests covering stale localStorage behavior and URL storage initialization.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
assets/js/services/local-storage.js Backfills missing URL keys at read time via merging defaults and adds per-product default fallback in getInfluxDBUrl().
cypress/e2e/influxdb-url.cy.js Adds E2E regression coverage to ensure undefined doesn’t appear in rendered API endpoint/code blocks and that storage initializes with expected keys.

You can also share your feedback on Copilot code review. Take the survey.

@jstirnaman jstirnaman merged commit e1f8358 into master Mar 18, 2026
13 checks passed
@jstirnaman jstirnaman deleted the claude/fix-issue-6960-sepRP branch March 18, 2026 16:25
jstirnaman added a commit that referenced this pull request Mar 22, 2026
…resolve-conflicts (#6976)

* Initial plan

* Add aliases to fix broken Docker Hub links to serve documentation

Co-authored-by: jstirnaman <[email protected]>

* fix(influxdb3): correct broken links causing 404s (#6958)

- Fix Power BI links in visualization-tools.md for cloud-dedicated,
  cloud-serverless, and clustered to use new visualize-data/ path
  instead of old process-data/visualize/ path
- Fix influxctl cluster list link in cloud-dedicated/admin/clusters/list.md
  to include missing cluster/ path segment

https://claude.ai/code/session_01SV14CdHN4GGVuATt9n7STn

Co-authored-by: Claude <[email protected]>

* fix(influxdb3): backfill missing product URLs in localStorage (#6961)

* fix(influxdb3): backfill missing product URLs in localStorage

Returning visitors with stale localStorage (created before core/enterprise
products were added) had undefined URL values for new products. The
updateUrls() function then replaced Hugo-rendered hostnames like
localhost:8181 with the string "undefined" in api-endpoint blocks.

Fix by merging DEFAULT_STORAGE_URLS as fallbacks when reading from
localStorage, so new product keys are always present.

closes #6960

https://claude.ai/code/session_01GJZ2yMR5DBk1feqTD5LeHW

* test(influxdb3): add Cypress tests for localStorage URL backfill

Adds 2 E2E tests for the fix in #6960:

1. Stale localStorage (missing `core` key) should not cause "undefined"
   to appear in api-endpoint or code blocks on the plugins page.
2. Fresh localStorage should be initialized with all expected product
   URL keys (oss, cloud, core, enterprise, serverless, dedicated, clustered).

Run with:
  node cypress/support/run-e2e-specs.js --spec "cypress/e2e/influxdb-url.cy.js" --no-mapping

https://claude.ai/code/session_01GJZ2yMR5DBk1feqTD5LeHW

---------

Co-authored-by: Claude <[email protected]>

* Remove `>` CLI prompts from runnable code blocks in InfluxQL/Flux/MongoDB docs (#6948)

* Initial plan

* fix(docs): remove > prompt from runnable code blocks

Remove leading `>` CLI prompt characters from code blocks that are meant
to be executed by users. Only keep `>` in code blocks that demonstrate
console output (showing both the command at the prompt AND the result output).

Changes affect 34 files across InfluxDB v1, Enterprise InfluxDB, shared
influxql-v3 reference, and Telegraf content:
- InfluxQL queries and management commands (sql/bash/no-lang blocks)
- Flux REPL examples (js blocks)
- MongoDB shell commands (shell blocks)

Preserved (unchanged):
- Console session blocks showing command + output (Type B: mixed > and non-> lines)
- Telegraf metric output blocks (text language with > measurement,tags format)
- diff blocks with < and > diff markers

Co-authored-by: jstirnaman <[email protected]>

* Apply suggestions from code review

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Apply suggestions from code review

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Update content/enterprise_influxdb/v1/query_language/continuous_queries.md

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jstirnaman <[email protected]>
Co-authored-by: Jason Stirnaman <[email protected]>
Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Add agentic workflow daily-repo-status (#6963)

* PR workflow: Improve review status signals and reduce noise (#6938)

* Initial plan

* Improve PR review workflow status signals and add agent personas

- Add Job 4 (report-skipped) to explicitly report when visual review is skipped
- Update resolve-review-urls.js to output skip status and reason
- Add clear agent persona headers to all bot comments (Preview Bot, Doc Review Bot)
- Reduce URL duplication by having visual review reference PR Preview comment
- Update copilot-visual-review.md template with completion signal format
- Add consistent status tables with emojis for clear at-a-glance status

Co-authored-by: jstirnaman <[email protected]>

* Address code review feedback

- Remove unnecessary comment about fallback default in resolve-review-urls.js
- Use plain text sanitization for skip reasons in preview comments
- Add clarifying comment about string comparison in GitHub Actions outputs

Co-authored-by: jstirnaman <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jstirnaman <[email protected]>
Co-authored-by: Jason Stirnaman <[email protected]>

* Initial plan

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jstirnaman <[email protected]>
Co-authored-by: Jason Stirnaman <[email protected]>
Co-authored-by: Claude <[email protected]>
Co-authored-by: Copilot Autofix powered by AI <[email protected]>
jstirnaman added a commit that referenced this pull request Mar 26, 2026
… visual review (#6974) (#6975)

* Initial plan

* Improve PR review workflow status signals and add agent personas

- Add Job 4 (report-skipped) to explicitly report when visual review is skipped
- Update resolve-review-urls.js to output skip status and reason
- Add clear agent persona headers to all bot comments (Preview Bot, Doc Review Bot)
- Reduce URL duplication by having visual review reference PR Preview comment
- Update copilot-visual-review.md template with completion signal format
- Add consistent status tables with emojis for clear at-a-glance status

Co-authored-by: jstirnaman <[email protected]>

* Address code review feedback

- Remove unnecessary comment about fallback default in resolve-review-urls.js
- Use plain text sanitization for skip reasons in preview comments
- Add clarifying comment about string comparison in GitHub Actions outputs

Co-authored-by: jstirnaman <[email protected]>

* doc-review: replace @github-copilot comment with GitHub Check Run for visual review (#6974)

* Initial plan

* Redesign visual review: replace @github-copilot comment with GitHub Check Run

- Replace PR comment mentioning @github-copilot (which never triggered
  Copilot Vision) with GitHub Check Run via checks.create/checks.update
- Add checks: write permission to Jobs 3 and 4; downgrade pull-requests
  to read-only (no more PR comment writes needed)
- Job 3 (copilot-visual-review): create in-progress check, wait for
  preview, complete as neutral with URLs+checklist or timeout message
- Job 4 (report-skipped): create a skipped check run instead of a comment
- Update DOC-REVIEW-PIPELINE-PLAN.md and LABEL_GUIDE.md to match

Co-authored-by: jstirnaman <[email protected]>
Agent-Logs-Url: https://github.com/influxdata/docs-v2/sessions/ef35b1d0-87cf-4b4f-92df-fff980a423c6

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jstirnaman <[email protected]>

* resolve conflicts: merge copilot/fix-broken-docker-link into copilot/resolve-conflicts (#6976)

* Initial plan

* Add aliases to fix broken Docker Hub links to serve documentation

Co-authored-by: jstirnaman <[email protected]>

* fix(influxdb3): correct broken links causing 404s (#6958)

- Fix Power BI links in visualization-tools.md for cloud-dedicated,
  cloud-serverless, and clustered to use new visualize-data/ path
  instead of old process-data/visualize/ path
- Fix influxctl cluster list link in cloud-dedicated/admin/clusters/list.md
  to include missing cluster/ path segment

https://claude.ai/code/session_01SV14CdHN4GGVuATt9n7STn

Co-authored-by: Claude <[email protected]>

* fix(influxdb3): backfill missing product URLs in localStorage (#6961)

* fix(influxdb3): backfill missing product URLs in localStorage

Returning visitors with stale localStorage (created before core/enterprise
products were added) had undefined URL values for new products. The
updateUrls() function then replaced Hugo-rendered hostnames like
localhost:8181 with the string "undefined" in api-endpoint blocks.

Fix by merging DEFAULT_STORAGE_URLS as fallbacks when reading from
localStorage, so new product keys are always present.

closes #6960

https://claude.ai/code/session_01GJZ2yMR5DBk1feqTD5LeHW

* test(influxdb3): add Cypress tests for localStorage URL backfill

Adds 2 E2E tests for the fix in #6960:

1. Stale localStorage (missing `core` key) should not cause "undefined"
   to appear in api-endpoint or code blocks on the plugins page.
2. Fresh localStorage should be initialized with all expected product
   URL keys (oss, cloud, core, enterprise, serverless, dedicated, clustered).

Run with:
  node cypress/support/run-e2e-specs.js --spec "cypress/e2e/influxdb-url.cy.js" --no-mapping

https://claude.ai/code/session_01GJZ2yMR5DBk1feqTD5LeHW

---------

Co-authored-by: Claude <[email protected]>

* Remove `>` CLI prompts from runnable code blocks in InfluxQL/Flux/MongoDB docs (#6948)

* Initial plan

* fix(docs): remove > prompt from runnable code blocks

Remove leading `>` CLI prompt characters from code blocks that are meant
to be executed by users. Only keep `>` in code blocks that demonstrate
console output (showing both the command at the prompt AND the result output).

Changes affect 34 files across InfluxDB v1, Enterprise InfluxDB, shared
influxql-v3 reference, and Telegraf content:
- InfluxQL queries and management commands (sql/bash/no-lang blocks)
- Flux REPL examples (js blocks)
- MongoDB shell commands (shell blocks)

Preserved (unchanged):
- Console session blocks showing command + output (Type B: mixed > and non-> lines)
- Telegraf metric output blocks (text language with > measurement,tags format)
- diff blocks with < and > diff markers

Co-authored-by: jstirnaman <[email protected]>

* Apply suggestions from code review

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Apply suggestions from code review

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Update content/enterprise_influxdb/v1/query_language/continuous_queries.md

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jstirnaman <[email protected]>
Co-authored-by: Jason Stirnaman <[email protected]>
Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Add agentic workflow daily-repo-status (#6963)

* PR workflow: Improve review status signals and reduce noise (#6938)

* Initial plan

* Improve PR review workflow status signals and add agent personas

- Add Job 4 (report-skipped) to explicitly report when visual review is skipped
- Update resolve-review-urls.js to output skip status and reason
- Add clear agent persona headers to all bot comments (Preview Bot, Doc Review Bot)
- Reduce URL duplication by having visual review reference PR Preview comment
- Update copilot-visual-review.md template with completion signal format
- Add consistent status tables with emojis for clear at-a-glance status

Co-authored-by: jstirnaman <[email protected]>

* Address code review feedback

- Remove unnecessary comment about fallback default in resolve-review-urls.js
- Use plain text sanitization for skip reasons in preview comments
- Add clarifying comment about string comparison in GitHub Actions outputs

Co-authored-by: jstirnaman <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jstirnaman <[email protected]>
Co-authored-by: Jason Stirnaman <[email protected]>

* Initial plan

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jstirnaman <[email protected]>
Co-authored-by: Jason Stirnaman <[email protected]>
Co-authored-by: Claude <[email protected]>
Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Initial plan (#6977)

Co-authored-by: copilot-swe-agent[bot] <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: Claude <[email protected]>
Co-authored-by: Copilot Autofix powered by AI <[email protected]>
jstirnaman added a commit that referenced this pull request Mar 26, 2026
…#6895)

* Initial plan

* Add aliases to fix broken Docker Hub links to serve documentation

Co-authored-by: jstirnaman <[email protected]>

* PR workflow: Improve review status signals and reduce noise (#6938)

* Initial plan

* Improve PR review workflow status signals and add agent personas

- Add Job 4 (report-skipped) to explicitly report when visual review is skipped
- Update resolve-review-urls.js to output skip status and reason
- Add clear agent persona headers to all bot comments (Preview Bot, Doc Review Bot)
- Reduce URL duplication by having visual review reference PR Preview comment
- Update copilot-visual-review.md template with completion signal format
- Add consistent status tables with emojis for clear at-a-glance status

Co-authored-by: jstirnaman <[email protected]>

* Address code review feedback

- Remove unnecessary comment about fallback default in resolve-review-urls.js
- Use plain text sanitization for skip reasons in preview comments
- Add clarifying comment about string comparison in GitHub Actions outputs

Co-authored-by: jstirnaman <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jstirnaman <[email protected]>
Co-authored-by: Jason Stirnaman <[email protected]>

* doc-review: replace @github-copilot comment with GitHub Check Run for visual review (#6974) (#6975)

* Initial plan

* Improve PR review workflow status signals and add agent personas

- Add Job 4 (report-skipped) to explicitly report when visual review is skipped
- Update resolve-review-urls.js to output skip status and reason
- Add clear agent persona headers to all bot comments (Preview Bot, Doc Review Bot)
- Reduce URL duplication by having visual review reference PR Preview comment
- Update copilot-visual-review.md template with completion signal format
- Add consistent status tables with emojis for clear at-a-glance status

Co-authored-by: jstirnaman <[email protected]>

* Address code review feedback

- Remove unnecessary comment about fallback default in resolve-review-urls.js
- Use plain text sanitization for skip reasons in preview comments
- Add clarifying comment about string comparison in GitHub Actions outputs

Co-authored-by: jstirnaman <[email protected]>

* doc-review: replace @github-copilot comment with GitHub Check Run for visual review (#6974)

* Initial plan

* Redesign visual review: replace @github-copilot comment with GitHub Check Run

- Replace PR comment mentioning @github-copilot (which never triggered
  Copilot Vision) with GitHub Check Run via checks.create/checks.update
- Add checks: write permission to Jobs 3 and 4; downgrade pull-requests
  to read-only (no more PR comment writes needed)
- Job 3 (copilot-visual-review): create in-progress check, wait for
  preview, complete as neutral with URLs+checklist or timeout message
- Job 4 (report-skipped): create a skipped check run instead of a comment
- Update DOC-REVIEW-PIPELINE-PLAN.md and LABEL_GUIDE.md to match

Co-authored-by: jstirnaman <[email protected]>
Agent-Logs-Url: https://github.com/influxdata/docs-v2/sessions/ef35b1d0-87cf-4b4f-92df-fff980a423c6

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jstirnaman <[email protected]>

* resolve conflicts: merge copilot/fix-broken-docker-link into copilot/resolve-conflicts (#6976)

* Initial plan

* Add aliases to fix broken Docker Hub links to serve documentation

Co-authored-by: jstirnaman <[email protected]>

* fix(influxdb3): correct broken links causing 404s (#6958)

- Fix Power BI links in visualization-tools.md for cloud-dedicated,
  cloud-serverless, and clustered to use new visualize-data/ path
  instead of old process-data/visualize/ path
- Fix influxctl cluster list link in cloud-dedicated/admin/clusters/list.md
  to include missing cluster/ path segment

https://claude.ai/code/session_01SV14CdHN4GGVuATt9n7STn

Co-authored-by: Claude <[email protected]>

* fix(influxdb3): backfill missing product URLs in localStorage (#6961)

* fix(influxdb3): backfill missing product URLs in localStorage

Returning visitors with stale localStorage (created before core/enterprise
products were added) had undefined URL values for new products. The
updateUrls() function then replaced Hugo-rendered hostnames like
localhost:8181 with the string "undefined" in api-endpoint blocks.

Fix by merging DEFAULT_STORAGE_URLS as fallbacks when reading from
localStorage, so new product keys are always present.

closes #6960

https://claude.ai/code/session_01GJZ2yMR5DBk1feqTD5LeHW

* test(influxdb3): add Cypress tests for localStorage URL backfill

Adds 2 E2E tests for the fix in #6960:

1. Stale localStorage (missing `core` key) should not cause "undefined"
   to appear in api-endpoint or code blocks on the plugins page.
2. Fresh localStorage should be initialized with all expected product
   URL keys (oss, cloud, core, enterprise, serverless, dedicated, clustered).

Run with:
  node cypress/support/run-e2e-specs.js --spec "cypress/e2e/influxdb-url.cy.js" --no-mapping

https://claude.ai/code/session_01GJZ2yMR5DBk1feqTD5LeHW

---------

Co-authored-by: Claude <[email protected]>

* Remove `>` CLI prompts from runnable code blocks in InfluxQL/Flux/MongoDB docs (#6948)

* Initial plan

* fix(docs): remove > prompt from runnable code blocks

Remove leading `>` CLI prompt characters from code blocks that are meant
to be executed by users. Only keep `>` in code blocks that demonstrate
console output (showing both the command at the prompt AND the result output).

Changes affect 34 files across InfluxDB v1, Enterprise InfluxDB, shared
influxql-v3 reference, and Telegraf content:
- InfluxQL queries and management commands (sql/bash/no-lang blocks)
- Flux REPL examples (js blocks)
- MongoDB shell commands (shell blocks)

Preserved (unchanged):
- Console session blocks showing command + output (Type B: mixed > and non-> lines)
- Telegraf metric output blocks (text language with > measurement,tags format)
- diff blocks with < and > diff markers

Co-authored-by: jstirnaman <[email protected]>

* Apply suggestions from code review

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Apply suggestions from code review

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Update content/enterprise_influxdb/v1/query_language/continuous_queries.md

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jstirnaman <[email protected]>
Co-authored-by: Jason Stirnaman <[email protected]>
Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Add agentic workflow daily-repo-status (#6963)

* PR workflow: Improve review status signals and reduce noise (#6938)

* Initial plan

* Improve PR review workflow status signals and add agent personas

- Add Job 4 (report-skipped) to explicitly report when visual review is skipped
- Update resolve-review-urls.js to output skip status and reason
- Add clear agent persona headers to all bot comments (Preview Bot, Doc Review Bot)
- Reduce URL duplication by having visual review reference PR Preview comment
- Update copilot-visual-review.md template with completion signal format
- Add consistent status tables with emojis for clear at-a-glance status

Co-authored-by: jstirnaman <[email protected]>

* Address code review feedback

- Remove unnecessary comment about fallback default in resolve-review-urls.js
- Use plain text sanitization for skip reasons in preview comments
- Add clarifying comment about string comparison in GitHub Actions outputs

Co-authored-by: jstirnaman <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jstirnaman <[email protected]>
Co-authored-by: Jason Stirnaman <[email protected]>

* Initial plan

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jstirnaman <[email protected]>
Co-authored-by: Jason Stirnaman <[email protected]>
Co-authored-by: Claude <[email protected]>
Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Initial plan (#6977)

Co-authored-by: copilot-swe-agent[bot] <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: Claude <[email protected]>
Co-authored-by: Copilot Autofix powered by AI <[email protected]>

* Move Docs review workflow plan to https://github.com/orgs/influxdata/projects/107?pane=issue&itemId=169574788

* Apply suggestions from code review

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: jstirnaman <[email protected]>
Co-authored-by: Jason Stirnaman <[email protected]>
Co-authored-by: Claude <[email protected]>
Co-authored-by: Copilot Autofix powered by AI <[email protected]>
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.

JavaScript returning undefined for the host

3 participants