NVIDIA / NVIDIA/OpenShell

Add high-level execute(code) helper for Python execution

Open
#1,816 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

state:triage-needed
Dominant language
Rust
Stars
8.7k
Forks
1.3k
Avg merge
2d 11h
Merged PRs (30d)
253

Description

Motivation

OpenShell already exposes lower-level execution paths, but common Python code execution should be available through a small, ergonomic helper. A high-level execute(code) API would make the Python SDK easier to use for agent and notebook-style workflows without changing the underlying protocol.

Proposed change

Add a Python SDK method similar to:

result = sandbox.execute("print('hello from OpenShell')")

The helper should wrap the existing exec_python / exec path where appropriate, preserve the lower-level APIs, and return the same execution result information callers can inspect today.

Acceptance criteria

  • Add a documented high-level execute(code: str, ...) helper to the Python SDK.
  • Preserve existing lower-level execution APIs without breaking changes.
  • Include unit tests for success, failure, timeout/error propagation, and result shape.
  • Add a README or docs example showing simple Python execution.

Notes

This should be SDK-only and should not require gateway/proto changes.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in the Python SDK at the existing exec_python and exec paths to understand their result shape, error handling, and timeout behavior. Add the documented execute(code: str, ...) helper while preserving those lower-level APIs, then run or add unit tests for success, failure, timeout/error propagation, and result shape, and update the README or docs with a simple example.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
api, documentation
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.