Skip to content

docs: fix getting-started client examples - #331

Open
Aryex wants to merge 3 commits into
mainfrom
fix/issue-326-client-examples
Open

Aryex wants to merge 3 commits into
mainfrom
fix/issue-326-client-examples

Conversation

@Aryex

@Aryex Aryex commented Sep 22, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Fix the outdated Python client-construction pattern reported in #326 and correct equivalent issues found while auditing the other language examples.

Issues

Closes #326

Changes

  • Create Python clients with GlideClientConfiguration and await GlideClient.create(...)
  • Await Node.js GlideClient.createClient(...) calls
  • Correct Java and Node.js TLS option names and the Java timeout value
  • Remove unsupported Python and PHP configuration options
  • Apply the Python and Node.js fixes to both the quickstart and basic-operations examples

Validation

  • pnpm build
  • Internal link validation passed as part of the build
  • git diff --check
  • Examples tested against GLIDE clients 2.5.1

Aryex and others added 3 commits September 22, 2026 10:33
@Aryex
Aryex marked this pull request as ready for review September 28, 2026 16:44
@Aryex Aryex self-assigned this Sep 28, 2026

@currantw currantw left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Reviewed to ede349e.

)
client = None

try:

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Is the try/catch block really needed for an example? Could we just have the happy path, so readers focus on the string operations? Do other Python examples also include try/catch every time we create/use/close a client?

require "valkey"

client = Valkey.new(host: "localhost", port: 6379)
client = nil

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Is this needed? Not sure about Ruby syntax, but could we just declare in begin?

Comment on lines +233 to +234
rescue StandardError => e
puts "Operation failed: #{e.message}"

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Similar to previous comment, is this necessary in a basic operations example? Or can we just assume the client gets created successfully?

@Aryex Aryex mentioned this pull request Nov 3, 2026
5 of 6 tasks
@jeremyprime

Copy link
Copy Markdown
Collaborator

Is this replaced mostly by #370?

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

4 participants