Skip to content

armgit / E2B

Public Imported from GitHub
0

Open-source, secure environment with real-world tools for enterprise-grade agents.

Fix outdated example in docs (#910)

Tomas Valenta345b2c4b4e47
diff --git a/apps/web/src/app/(docs)/docs/sandbox-template/start-cmd/page.mdx b/apps/web/src/app/(docs)/docs/sandbox-template/start-cmd/page.mdx
index 06002667e..90f214f7c 100644
--- a/apps/web/src/app/(docs)/docs/sandbox-template/start-cmd/page.mdx
+++ b/apps/web/src/app/(docs)/docs/sandbox-template/start-cmd/page.mdx
@@ -30,50 +30,14 @@ You can specify the start command also inside the `e2b.toml` in the same directo
## Logs
-You can retrieve the start command's logs using the SDK during runtime.
-
-<Note>
-These logs are the logs from the start command during the build phase.
-</Note>
-
-<CodeGroup title="Check start command logs" isRunnable={false}>
-```js {{ language: 'js' }}
-import { Sandbox } from 'e2b'
-
-// Spawn your custom sandbox
-const sandbox = await Sandbox.create({
- id: 'my-agent-sandbox',
- // If you specify onStderr and onStdout handlers when spawning the sandbox
- // you will see logs from the start command.
- onStderr: output => console.log("stderr", output.line), // $HighlightLine
- onStdout: output => console.log("stdout", output.line), // $HighlightLine
-})
-
-// Close sandbox once done
-await sandbox.close()
-```
-
-```python {{ language: 'python' }}
-from e2b import Sandbox
-
-# Spawn your custom sandbox
-sandbox = Sandbox.create(
- id="my-agent-sandbox",
- # If you specify on_stderr and on_stdout handlers when spawning the sandbox
- # you will see logs from the start command.
- on_stderr=lambda output: print("stderr", output.line), # $HighlightLine
- on_stdout=lambda output: print("stdout", output.line), # $HighlightLine
-)
-
-# Close sandbox once done
-sandbox.kill()
-```
-</CodeGroup>
-
-Or you can use the CLI:
+You can retrieve the start command's logs using the CLI:
<CodeGroup isTerminalCommand>
```bash {{ language: 'bash' }}
e2b sandbox logs <sandbox-id>
```
</CodeGroup>
+
+<Note>
+These logs include logs from the start command during the build phase.
+</Note>