Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

502 Timeout Error #592

Open
manavAt1flow opened this issue Feb 25, 2025 · 5 comments
Open

502 Timeout Error #592

manavAt1flow opened this issue Feb 25, 2025 · 5 comments

Comments

@manavAt1flow
Copy link

manavAt1flow commented Feb 25, 2025

Getting Sandbox timeout errors all the time, could you please help me what can be wrong here?

import dotenv from 'dotenv'
import { Sandbox } from '@e2b/code-interpreter'

dotenv.config()

const sandbox = await Sandbox.create("code-interpreter-v1", {
    timeoutMs: 300000,
    requestTimeoutMs: 300000,
})

const execution = await sandbox.runCode('x = 1;x+=1; x')

console.log(execution.text)

Error Response

       return new import_e2b.TimeoutError(
               ^

TimeoutError: <html>
<head><title>502 Bad Gateway</title></head>
<body>
<center><h1>502 Bad Gateway</h1></center>
<hr><center>nginx/1.27.0</center>
</body>
</html>
: This error is likely due to sandbox timeout. You can modify the sandbox timeout by passing 'timeoutMs' when starting the sandbox or calling '.setTimeout' on the sandbox with the desired timeout.
Copy link

linear bot commented Feb 25, 2025

@jakubno
Copy link
Member

jakubno commented Feb 25, 2025

Is this running on the e2b cloud or your self-hosted version? If it's the self-hosted version, could you check if you included the start command when building the code interpreter template?

@manavAt1flow
Copy link
Author

manavAt1flow commented Feb 25, 2025

Hey @jakubno, Yes its self-hosted version, i am following according to docs https://e2b.dev/docs/quickstart/install-custom-packages

Here is e2b.Dockerfile

FROM e2bdev/code-interpreter:latest

# Install some Python packages
RUN pip install cowsay

@manavAt1flow
Copy link
Author

Getting this while building template with build start cmd.

 Error getting template build status: [500] internal server error: Failed to get the default team

@haodaohong
Copy link

I got the same issue error 500 fetch failed。 use e2b cloud

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

No branches or pull requests

3 participants