Skip to content

feat: Deterministic container naming for traceability #265#266

Merged
ArthurCRodrigues merged 2 commits intomainfrom
265-deterministic-sandbox-naming
Apr 10, 2026
Merged

feat: Deterministic container naming for traceability #265#266
ArthurCRodrigues merged 2 commits intomainfrom
265-deterministic-sandbox-naming

Conversation

@LuisHenriqueDC301
Copy link
Copy Markdown
Contributor

Summary

Adopts a deterministic, human-readable naming convention for sandbox containers: ag-sbx-{lang}-{pool8}-{seq4}.

Examples: ag-sbx-python-a1b2c3d4-0001, ag-sbx-node-a1b2c3d4-0002

Changes

  • sandbox_manager/language_pool.py — Added per-pool sequence counter, _build_container_name() helper, and name= parameter in both gVisor and fallback container creation paths
  • sandbox_manager/sandbox_container.py — Updated __repr__ to include container name
  • sandbox_manager/manager.py — Orphan cleanup logs now include container name alongside id
  • tests/unit/test_sandbox_manager.py — Unit tests for name format and sequence incrementing
  • tests/integration/test_sandbox_lifecycle.py — Integration tests for deterministic naming and sequence progression
  • docs/architecture/sandbox_manager.md — Documented naming convention in Container Security section

Closes #265

Copy link
Copy Markdown
Member

@ArthurCRodrigues ArthurCRodrigues left a comment

Choose a reason for hiding this comment

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

Please remove the emojis from the logs

@ArthurCRodrigues ArthurCRodrigues merged commit 160241b into main Apr 10, 2026
3 checks passed
@ArthurCRodrigues ArthurCRodrigues deleted the 265-deterministic-sandbox-naming branch April 10, 2026 20:23
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.

[Sandbox] Deterministic container naming for traceability

2 participants