Skip to content

docs: correct client examples and guidance - #370

Open
Aryex wants to merge 6 commits into
mainfrom
alexl/docs-catchup-corrections
Open

Aryex wants to merge 6 commits into
mainfrom
alexl/docs-catchup-corrections

Conversation

@Aryex

@Aryex Aryex commented Nov 3, 2026 •

Copy link
Copy Markdown
Collaborator

Human Overview

This PR correct various code examples in docs as well as update a few missed TabItem to ClientTab.

Summary

Correct examples and guidance that no longer match the current client APIs or runtime behavior.

Issue link

Closes #326. The other fixes come from the local docs gap audit.

Content changes

  • Fix lazy-connection and reconnect examples across clients.
  • Correct Node.js and Go configuration types, imports, and timeout values.
  • Fix scripting and troubleshooting examples that use invalid APIs.
  • Correct TLS examples and related connection guidance.
  • Correct getting-started client construction and configuration while keeping operation-focused snippets concise.
  • Fix the remaining example bugs found while verifying against the latest rc client builds, including the TLS custom-cert cleanup and mislabeled request timeouts.
  • Migrate the client pool and isolated scope tabs to ClientTabs, and remove unused component imports.

Implementation

The changes stay within existing pages and preserve equivalent flows across language tabs. This PR incorporates the still-relevant API corrections from #331, but intentionally omits broad try/catch wrappers from simple operation and configuration snippets. New feature documentation and the pool/scope/recovery updates are in separate drafts.

Testing

  • pnpm run format:check
  • pnpm build
  • Internal link validation during the Astro build

Checklist

  • This Pull Request is related to one issue.
  • Commit message has a detailed description of what changed and why.
  • All commits are signed off with --signoff flag.
  • pnpm build runs successfully.
  • Internal links have been checked for validity.
  • Destination branch is main.

Aryex added 5 commits November 5, 2026 19:19
Fix invalid or misleading examples for lazy connections, reconnect behavior, connection options, scripting, troubleshooting, and TLS across the supported clients.

Signed-off-by: Alex Le <alex.le@improving.com>
Correct client creation, TLS option names, timeout values, and unsupported configuration fields while keeping operation-focused snippets concise.

Signed-off-by: Alex Le <alex.le@improving.com>
Verified the examples touched by this PR against the latest client
builds (Python/Node/Java/Go 2.6.0-rc3, C# 1.1.0, PHP 1.2.0-rc1, Ruby
1.1.0.pre.rc1) and fixed the remaining problems:

- TLS tutorial: the custom-cert example called client.is_connected(),
  which does not exist, so it raised AttributeError after a successful
  connection. Initialize client to None and guard close() instead.
- Quickstart config: label request_timeout as the request timeout, not
  the connection timeout; drop the inaccurate "0-15" database range.
- Quickstart PHP config: keep only the options the other tabs set. This
  also removes 'factor' => 2.0, which the extension silently ignored.
- Quickstart Python: decode the ping response so it prints PONG, matching
  the documented output.
- Go basic operations: print value.Value() instead of the Result struct.
- Go examples: rename the config variable to cfg so it no longer shadows
  the config package.

Signed-off-by: Alex Le <alex.le@improving.com>
Replace the legacy Starlight <Tabs>/<TabItem> client-language tab groups
with the <ClientTabs>/<ClientTab> components:

- how-to/client-pool.mdx: 6 tab groups (24 tabs)
- how-to/isolated-scope.mdx: 3 tab groups (12 tabs)

Also remove the unused Tabs/TabItem imports from
concepts/client-features/modules.mdx and pubsub-model.mdx.

Remaining TabItem usage is for generic choices (Gradle/Maven,
sync/async, migration comparisons) rather than client languages.

Signed-off-by: Alex Le <alex.le@improving.com>
Drop the Aside import from concepts/client-features/modules.mdx and
pubsub-model.mdx; neither page uses the component.

Signed-off-by: Alex Le <alex.le@improving.com>
@Aryex
Aryex force-pushed the alexl/docs-catchup-corrections branch from 7df9c8a to 926b343 Compare November 5, 2026 19:20
@Aryex Aryex self-assigned this Nov 5, 2026
@Aryex
Aryex marked this pull request as ready for review November 5, 2026 19:21
- Close the client in the quickstart Go connection configuration example.
- Decode Python GET and MGET results so they print as strings.
- Use port 6379 in the Go connection options example and drop the
  package clause, matching the other snippets.

Signed-off-by: Alex Le <alex.le@improving.com>

This branch has not been deployed

No deployments
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.

Python: quickstart snippet fails

2 participants