Skip to content

fix(server): include manually created k8s sandboxes in list API#411

Open
suger-m wants to merge 1 commit intoalibaba:mainfrom
suger-m:fix/issue-409-manual-k8s-list
Open

fix(server): include manually created k8s sandboxes in list API#411
suger-m wants to merge 1 commit intoalibaba:mainfrom
suger-m:fix/issue-409-manual-k8s-list

Conversation

@suger-m
Copy link
Contributor

@suger-m suger-m commented Mar 10, 2026

Summary

  • list k8s workloads without requiring opensandbox.io/id label
  • fallback sandbox id to workload metadata.name when the label is missing
  • add unit test for manually created BatchSandbox without id label

Validation

  • uv run pytest tests/k8s/test_kubernetes_service.py -q
  • uv run pytest tests/test_routes_list_sandboxes.py -q
  • uv run ruff check src/services/k8s/kubernetes_service.py tests/k8s/test_kubernetes_service.py

Fixes #409

@chatgpt-codex-connector
Copy link

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Credits must be used to enable repository wide code reviews.

@CLAassistant
Copy link

CLAassistant commented Mar 10, 2026

CLA assistant check
All committers have signed the CLA.

@jwx0925
Copy link
Collaborator

jwx0925 commented Mar 11, 2026

@codex review

@chatgpt-codex-connector
Copy link

Codex Review: Didn't find any major issues. 🚀

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

component/server feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

希望sandbox-server可以管理通过k8s创建的沙箱

5 participants