Skip to content

feat(sdk/python): add async PoolManager and PoolsAdapter#358

Open
wangdengshan wants to merge 2 commits into
alibaba:mainfrom
wangdengshan:feat/sdk-python-pool-manager-async
Open

feat(sdk/python): add async PoolManager and PoolsAdapter#358
wangdengshan wants to merge 2 commits into
alibaba:mainfrom
wangdengshan:feat/sdk-python-pool-manager-async

Conversation

@wangdengshan
Copy link
Copy Markdown
Contributor

Summary

  • Add async PoolManager and PoolsAdapter to the Python SDK for managing pre-warmed sandbox pools
  • Add domain models: PoolCapacitySpec, PoolStatus, PoolInfo, PoolListResponse, CreatePoolParams, UpdatePoolParams
  • Add Pools Protocol (async service interface)
  • Add attrs-style API lifecycle models for all pool schemas
  • Add 5 API modules (post/get/list/put/delete) with both asyncio_detailed and sync_detailed functions
  • Add PoolsAdapter (async HTTP adapter using httpx.AsyncClient)
  • Add PoolManager with static create(), CRUD methods, and async context manager (__aenter__/__aexit__)
  • Export PoolManager from opensandbox root __init__

Testing

  • Unit tests
  • 41 tests covering models, adapter mapping, and manager logic

Breaking Changes

  • None

Checklist

  • Linked Issue or clearly described motivation
  • Added/updated docs (if needed)
  • Added/updated tests (if needed)
  • Security impact considered
  • Backward compatibility considered

- Add domain models: PoolCapacitySpec, PoolStatus, PoolInfo,
  PoolListResponse, CreatePoolParams, UpdatePoolParams
- Add Pools Protocol (async service interface)
- Add attrs-style API lifecycle models for all pool schemas
- Add 5 API modules (post/get/list/put/delete) with both
  asyncio_detailed and sync_detailed functions
- Add PoolsAdapter (async HTTP adapter using httpx.AsyncClient)
- Add PoolManager with static create(), CRUD methods, and
  async context manager (__aenter__/__aexit__)
- Export PoolManager from opensandbox root __init__
- Add 41 tests covering models, adapter mapping, and manager logic
@wangdengshan wangdengshan requested a review from Pangjiping as a code owner May 25, 2026 08:49
@github-actions
Copy link
Copy Markdown
Contributor

⚠️ This PR has no labels. Please add one based on the changes.

Changed directories: sdks.

📋 Recommended labels (based on changed files):

  • sdks ⬅️

Other available labels:

  • bug - Something isn't working
  • dependencies - Pull requests that update a dependency file
  • documentation - Improvements or additions to documentation
  • feature - New feature or request
  • packages - Changes for package, image and configuration

💡 Tip: Use feature for new functionality or improvements, bug for fixes.

cc @wangdengshan

@wangdengshan
Copy link
Copy Markdown
Contributor Author

Hi maintainers, could someone please add the sdks and feature labels to this PR? As an external contributor I do not have permission to add labels myself. Thanks!

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

Successfully merging this pull request may close these issues.

1 participant