Skip to content

feat(platform): introduce platform support for sandbox lifecycle#645

Merged
ninan-nn merged 11 commits intoalibaba:mainfrom
hittyt:feat/platform-support
Apr 8, 2026
Merged

feat(platform): introduce platform support for sandbox lifecycle#645
ninan-nn merged 11 commits intoalibaba:mainfrom
hittyt:feat/platform-support

Conversation

@hittyt
Copy link
Copy Markdown
Collaborator

@hittyt hittyt commented Apr 5, 2026

Summary

Introduce an optional platform object in the sandbox lifecycle spec and treat it as a scheduling/runtime constraint rather than as part of image.
Align platform behavior across spec, server, and SDK surfaces by adding explicit platform constraints, preserving Docker default compatibility, and failing fast only for platform-specific Kubernetes unschedulable states.

Testing

  • Not run (explain why)
  • Unit tests
  • Integration tests
  • e2e / manual verification

Breaking Changes

  • None
  • Yes (describe impact and migration path)

Checklist

Align platform behavior across spec, server, and SDK surfaces by adding explicit platform constraints, preserving Docker default compatibility, and failing fast only for platform-specific Kubernetes unschedulable states.

Made-with: Cursor
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: bd6658ef73

ℹ️ 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".

hittyt added 5 commits April 5, 2026 17:54
Normalize Python and Kotlin sandbox converters to handle generated platform/network enum representations correctly, and apply formatter-compliant test imports so SDK quality checks pass consistently.

Made-with: Cursor
Use dict-based API PlatformSpec construction and enum-safe value extraction so converter logic works with both string-backed and enum-backed generated models.

Made-with: Cursor
Align platform handling with runtime-specific defaults, make Docker image/platform resolution safer for omitted platform requests, and document the behavior explicitly so SDK and API contracts stay consistent.

Made-with: Cursor
Make pool reconcile assertions order-insensitive and harden C# code-interpreter E2E checks with retries and broader stream event acceptance to avoid timing-related false negatives.

Made-with: Cursor
Update pool reconciler state test to assert set membership and cardinality instead of fixed id ordering so concurrent warmup scheduling does not cause flaky failures.

Made-with: Cursor
hittyt added 4 commits April 7, 2026 11:52
…ntract

Extract duplicated k8s platform selector/affinity validation into shared workload provider helpers, remove unused k8s client node read API, and realign spec/server/sdk validation to linux-only platform support for now.

Made-with: Cursor
Made-with: Cursor

# Conflicts:
#	server/opensandbox_server/services/k8s/kubernetes_service.py
Align sandbox platform conversion with linux-only OpenAPI contract to prevent Kotlin compilation failures after codegen.

Made-with: Cursor
Prevent _wait_for_sandbox_ready from swallowing TypeError and timing out by restoring _normalize_create_status static dispatch.

Made-with: Cursor
@hittyt hittyt requested a review from Pangjiping April 7, 2026 07:47
Made-with: Cursor

# Conflicts:
#	tests/csharp/OpenSandbox.E2ETests/CodeInterpreterE2ETests.cs
Copy link
Copy Markdown
Collaborator

@Pangjiping Pangjiping left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Copy Markdown
Collaborator

@ninan-nn ninan-nn left a comment

Choose a reason for hiding this comment

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

LGTM

@ninan-nn ninan-nn merged commit 602b9f8 into alibaba:main Apr 8, 2026
22 checks passed
@hittyt hittyt deleted the feat/platform-support branch April 10, 2026 13:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants