Skip to content

fix(vercel): use python3.13 runtime in Vercel Sandbox Python examples#4835

Open
Elisabeth Rulke (erulkey) wants to merge 1 commit into
langchain-ai:mainfrom
erulkey:fix/vercel-sandbox-python-runtime
Open

fix(vercel): use python3.13 runtime in Vercel Sandbox Python examples#4835
Elisabeth Rulke (erulkey) wants to merge 1 commit into
langchain-ai:mainfrom
erulkey:fix/vercel-sandbox-python-runtime

Conversation

@erulkey

@erulkey Elisabeth Rulke (erulkey) commented Jul 10, 2026

Copy link
Copy Markdown

What

The Vercel Sandbox Python examples create the sandbox with Sandbox.create() and no runtime, which defaults to node24 (Vercel's JavaScript runtime). The same examples then run Python (python --version, "run pytest", etc.), so following them as written fails.

Repro (live)

Running the example verbatim with langchain-vercel-sandbox 0.0.1 + vercel 0.5.9:

sandbox = Sandbox.create()                     # defaults to node24
backend.execute("python --version")
# output:    'bash: line 1: python: command not found'
# exit_code: 127

With the one-line change:

sandbox = Sandbox.create(runtime="python3.13")
backend.execute("python --version")
# output:    'Python 3.13.1'
# exit_code: 0

Per Vercel's docs, python3.13 is the only runtime that ships python/pip/uv; the node* runtimes ship npm/pnpm only (runtimes docs). Vercel's own Python example uses runtime: "python3.13".

Change

Adds runtime="python3.13" to the 7 Vercel Python snippets:

  • src/oss/python/integrations/sandboxes/vercel.mdx (2)
  • src/oss/deepagents/sandboxes.mdx (3)
  • src/snippets/sandboxes-basic-tabs-py.mdx (1)
  • src/snippets/deepagents-sandbox-basic-py.mdx (1)

The JS example already sets runtime: "node24" and runs TypeScript (verified: node hello.ts works on node24), so it's unaffected.

@github-actions github-actions Bot added external User is not a member of langchain-ai deepagents For docs changes to Deep Agents langchain For docs changes to LangChain oss python For content related to the Python version of LangChain projects labels Jul 10, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Thanks for opening a docs PR, Elisabeth Rulke (@erulkey)! When it's ready for review, please add the relevant reviewers:

  • @npentrel or @lnhsingh (Deep Agents)
  • @mdrxy (Python integrations)

The Vercel Sandbox Python examples call Sandbox.create() with no runtime,
which defaults to node24 (Vercel's JavaScript runtime), then run Python.
Following them as written fails: python/pip/uv are only present on the
python3.13 runtime.

Reproduced live (langchain-vercel-sandbox 0.0.1 + vercel 0.5.9):
  Sandbox.create()                       -> node24
    backend.execute("python --version")  => "bash: python: command not found", exit 127
  Sandbox.create(runtime="python3.13")
    backend.execute("python --version")  => "Python 3.13.1", exit 0

Adds runtime="python3.13" to the 7 Vercel Python snippets. The JS example
already sets runtime: "node24" and runs TypeScript, so it is unaffected.
@erulkey Elisabeth Rulke (erulkey) force-pushed the fix/vercel-sandbox-python-runtime branch from f037511 to 62ffacf Compare July 11, 2026 01:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

deepagents For docs changes to Deep Agents external User is not a member of langchain-ai langchain For docs changes to LangChain oss python For content related to the Python version of LangChain projects

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant