Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/openenv/cli/templates/openenv_env/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ The simplest way to use the __ENV_TITLE_NAME__ environment is through the `__ENV
from __ENV_NAME__ import __ENV_CLASS_NAME__Action, __ENV_CLASS_NAME__Env

try:
# Create environment from Docker image
__ENV_NAME__env = __ENV_CLASS_NAME__Env.from_docker_image("__ENV_NAME__-env:latest")
# Create environment from Docker image (.sync() for synchronous use)
__ENV_NAME__env = __ENV_CLASS_NAME__Env.from_docker_image("__ENV_NAME__-env:latest").sync()

# Reset
result = __ENV_NAME__env.reset()
Expand Down
4 changes: 2 additions & 2 deletions src/openenv/cli/templates/openenv_env/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ class __ENV_CLASS_NAME__Env(
... print(result.observation.echoed_message)

Example with Docker:
>>> # Automatically start container and connect
>>> client = __ENV_CLASS_NAME__Env.from_docker_image("__ENV_NAME__-env:latest")
>>> # Automatically start container and connect (.sync() for sync use)
>>> client = __ENV_CLASS_NAME__Env.from_docker_image("__ENV_NAME__-env:latest").sync()
>>> try:
... result = client.reset()
... result = client.step(__ENV_CLASS_NAME__Action(message="Test"))
Expand Down
Loading
Loading