Skip to content

Conversation

@0div
Copy link
Contributor

@0div 0div commented Apr 18, 2025

  • js-sdk
    • successful build?
    • successful unit tests?
  • python-sdk
    • successful build?
    • successful unit tests?

@mishushakov
Copy link
Member

keep in mind in the API client, I had to manually overwrite get_v2_sandboxes function so the state is passed correctly to the API

Screenshot 2025-04-21 at 17 23 30

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why commented out?

Copy link
Member

@mishushakov mishushakov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

was this line changed in sandbox api .py error handling?

- if res.status_code >= 300
+ if res.status_code >= 300 or isinstance(res.parsed, Error)

can res.parsed even be an error?

@0div
Copy link
Contributor Author

0div commented Apr 21, 2025

was this line changed in sandbox api .py error handling?

- if res.status_code >= 300
+ if res.status_code >= 300 or isinstance(res.parsed, Error)

can res.parsed even be an error?

This seems in line with the open API spec, response can be [200] {Object} or [> 300] Error

@mishushakov
Copy link
Member

will handle_api_exception process it correctly though?

Copy link
Member

ValentaTomas commented Apr 22, 2025

keep in mind in the API client, I had to manually overwrite get_v2_sandboxes function so the state is passed correctly to the API

Quick question here—is this a problem of the API client not being able to compose the state field properly, because it is too complicated?
Another question—the override is added in our code, not in the generated code, right?

@ValentaTomas ValentaTomas added the feature New feature or request label Apr 22, 2025
@mishushakov
Copy link
Member

@ValentaTomas we are using a query parameter format that the API client does not generate correctly for some reason (state=paused,running vs state=paused&state=running), the override had to be added to the generated code

@0div
Copy link
Contributor Author

0div commented Apr 23, 2025

@ValentaTomas, GTM?

@0div 0div merged commit 500e5cb into add-autopause-option-to-sdk-e2b-1461 Apr 23, 2025
2 checks passed
@0div 0div deleted the autopause-beta-with-list-v2 branch April 23, 2025 18:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants