OpenParable
Skip to content
← Back to skills

Apple Container

Testing & Quality
apple-container

Apple Container is an Agent Skill for testing & quality published in the RustPython/RustPython repository on GitHub: a SKILL.md instruction file an AI agent can load to do this task.

Run RustPython tests in Apple's `container` CLI Linux environment. Use when user asks to run or compare Linux test results on macOS.

View on GitHub ↗
QUICK START

How to use this skill

Bring this guide into your coding agent with a prompt tailored to the tool you use.

  1. Open your project in Codex.
  2. Copy and paste the prompt below.
  3. Review files and risks before approving any action.
Prompt to paste
Inspect the Agent Skill at https://github.com/RustPython/RustPython/blob/HEAD/.agents/skills/apple-container/SKILL.md and all supporting files. Report provenance, permissions, scripts, dependencies, and security risks. Propose an exact installation into .agents/skills/apple-container, but wait for my approval before writing files or running scripts.

Copying this prompt does not install or run the skill. Review third-party files before use.

Run Tests in Linux Container (Apple container CLI)

Run RustPython tests inside a Linux container using Apple's container CLI. NEVER use Docker, Podman, or any other container runtime. Only use the container command.

Arguments

  • Test command to run (examples: test_io, test_codecs -v, test_io -v -m "test_errors")

Prerequisites

  • The container CLI is installed via brew install container.
  • The dev image rustpython-dev is already built.

Workflow

  1. Check whether the test container is already running:

    container list 2>/dev/null | grep rustpython-test
    
  2. Start the container if it is not running:

    container run -d --name rustpython-test -m 8G -c 4 \
        --mount type=bind,source="$(pwd)",target=/workspace \
        -w /workspace rustpython-dev sleep infinity
    
  3. Run the requested test command inside the container:

    container exec rustpython-test cargo run --release -- -m test <test-args>
    
  4. Report results:

  • Show pass/fail summary and expected failures / unexpected successes.
  • Highlight new failures compared to macOS results, if available.
  • Do not stop or remove the container after testing.

Notes

  • The workspace is bind-mounted, so local code changes are immediately available in the container.

  • Use container exec rustpython-test sh -c "..." for any command inside the container.

  • Rebuild after code changes with:

    container exec rustpython-test sh -c "cargo build --release"
    
  • Stop the container when explicitly requested:

    container rm -f rustpython-test