feat: unified sandbox suspension and E2B idle pause/resume #121
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: native-check | |
| on: | |
| pull_request: | |
| paths: | |
| - 'apps/daemon/**' | |
| - 'internal/**' | |
| - 'contracts/agents-api/**' | |
| - 'packages/claude-sdk-adapter/**' | |
| - 'packages/mcode-harness/**' | |
| - 'packages/tsconfig/**' | |
| - 'scripts/build-native-installer*' | |
| - 'scripts/native-harness-smoke.mjs' | |
| - 'scripts/native-onboarding-smoke.mjs' | |
| - 'services/core/internal/nativeinstaller/**' | |
| - 'scripts/build-mcode-harness.sh' | |
| - 'go.mod' | |
| - 'go.sum' | |
| - 'go.work' | |
| - 'go.work.sum' | |
| - 'package.json' | |
| - 'pnpm-lock.yaml' | |
| - 'pnpm-workspace.yaml' | |
| - 'tsconfig.base.json' | |
| - '.npmrc' | |
| - '.github/workflows/native.yml' | |
| workflow_dispatch: | |
| workflow_call: | |
| inputs: | |
| ref: | |
| type: string | |
| required: true | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: native-check-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| platform: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - platform: linux-amd64 | |
| runner: blacksmith-2vcpu-ubuntu-2204 | |
| github-runner: ubuntu-22.04 | |
| - platform: darwin-arm64 | |
| runner: macos-15 | |
| github-runner: macos-15 | |
| - platform: windows-amd64 | |
| runner: blacksmith-2vcpu-windows-2025 | |
| github-runner: windows-2025 | |
| name: platform (${{ matrix.platform }}) | |
| runs-on: ${{ vars.OAC_USE_GITHUB_RUNNERS == 'true' && matrix.github-runner || matrix.runner }} | |
| timeout-minutes: 30 | |
| defaults: | |
| run: | |
| shell: bash | |
| steps: | |
| - uses: actions/checkout@v7 | |
| with: | |
| ref: ${{ inputs.ref || github.sha }} | |
| - uses: actions/setup-go@v7 | |
| with: | |
| go-version-file: go.mod | |
| - uses: actions/setup-node@v6 | |
| with: | |
| node-version: '22.22.0' | |
| - name: Build the native daemon and test bundle boundaries | |
| run: | | |
| go build -ldflags "-X github.com/MiniMax-AI/OpenAgentCore/apps/daemon/internal/cli.Version=$(git rev-parse HEAD)" -o "$RUNNER_TEMP/oac-daemon${{ runner.os == 'Windows' && '.exe' || '' }}" ./apps/daemon/cmd/oac-daemon | |
| node --test scripts/build-native-installer.test.mjs | |
| - name: Native filesystem, authentication and process lifecycle | |
| run: >- | |
| go test -race -count=1 | |
| ./internal/runtimefs | |
| ./apps/daemon/internal/auth | |
| ./apps/daemon/internal/paths | |
| ./apps/daemon/internal/daemonize | |
| ./apps/daemon/internal/agent/clirunner | |
| - name: Native Harness ownership and environment identity | |
| run: >- | |
| go test -race -count=1 | |
| ./apps/daemon/internal/agent/codex | |
| ./apps/daemon/internal/agent/claudesdk | |
| ./apps/daemon/internal/agent/mcode | |
| -run 'TestJSONRPCClientOwnsToolDescendants|TestSelfHostedToolEnvironment' | |
| - name: Native capability snapshots, files and installation | |
| run: >- | |
| go test -race -count=1 | |
| ./apps/daemon/internal/localworkspace | |
| ./apps/daemon/internal/cli | |
| -run 'TestNative|TestRuntimeInit|TestRuntimePreparationRejects|TestPreparationFreezesLocalContentsAcrossReconnect|TestSnapshotMarker' | |
| - name: Windows npm and npx stdio launchers without network | |
| if: runner.os == 'Windows' | |
| run: >- | |
| go test -race -count=1 -timeout=2m | |
| ./apps/daemon/internal/localworkspace | |
| ./apps/daemon/internal/cli | |
| -run 'TestWindowsPackageManager|TestWindowsRuntimeMCP' | |
| - name: Build pinned native components | |
| run: | | |
| npm install --global pnpm@10.30.3 | |
| pnpm install --frozen-lockfile --filter @oac/claude-sdk-adapter... | |
| pnpm --filter @oac/claude-sdk-adapter build --outDir "$RUNNER_TEMP/claude-compiled" | |
| pnpm --config.inject-workspace-packages=true --config.extend-node-path=false --filter @oac/claude-sdk-adapter deploy --prod "$RUNNER_TEMP/claude-runtime" | |
| rm -rf "$RUNNER_TEMP/claude-runtime/dist" | |
| mv "$RUNNER_TEMP/claude-compiled" "$RUNNER_TEMP/claude-runtime/dist" | |
| # Reify the dedicated frozen export lock without pnpm's symlink layout. | |
| # Flattening isolated package links changes Node dependency resolution. | |
| rm -rf "$RUNNER_TEMP/claude-runtime/node_modules" | |
| pnpm --dir "$RUNNER_TEMP/claude-runtime" install --prod --frozen-lockfile --config.node-linker=hoisted --ignore-scripts | |
| npm install --prefix "$RUNNER_TEMP/native-tools" --no-save @openai/codex@0.153.4 | |
| - name: Build the pinned MiniMax companion on Unix | |
| if: runner.os != 'Windows' | |
| run: | | |
| source_repository="$(node -p 'require("./packages/mcode-harness/source.json").repository')" | |
| source_revision="$(node -p 'require("./packages/mcode-harness/source.json").revision')" | |
| source_version="$(node -p 'require("./packages/mcode-harness/source.json").version')" | |
| git init --quiet "$RUNNER_TEMP/mcode-source" | |
| git -C "$RUNNER_TEMP/mcode-source" remote add origin "$source_repository" | |
| git -C "$RUNNER_TEMP/mcode-source" fetch --depth 1 origin "$source_revision" | |
| git -C "$RUNNER_TEMP/mcode-source" checkout --detach FETCH_HEAD | |
| npm install --prefix "$RUNNER_TEMP/mcode-native" --no-audit --no-fund --include=optional --install-strategy=nested "@minimax-ai/code@$source_version" | |
| MCODE_NATIVE_SOURCE="$RUNNER_TEMP/mcode-source" \ | |
| MCODE_CLI_DIR="$RUNNER_TEMP/mcode-native/node_modules/@minimax-ai/code" \ | |
| MCODE_HARNESS_BUILD_DIR="$RUNNER_TEMP/minimax-runtime" \ | |
| bash scripts/build-mcode-harness.sh | |
| - name: Package and exercise CLI-only installation, additions and reuse | |
| run: | | |
| if [[ "$RUNNER_OS" == Windows ]]; then | |
| export CLAUDE_CODE_GIT_BASH_PATH='C:\Program Files\Git\bin\bash.exe' | |
| fi | |
| node scripts/build-native-installer-ci.mjs | |
| - name: Bootstrap, authenticate, install and connect natively | |
| run: node scripts/native-onboarding-smoke.mjs | |
| - name: Verify native Harness protocols without model requests | |
| run: | | |
| if [[ "$RUNNER_OS" == Windows ]]; then | |
| export CLAUDE_CODE_GIT_BASH_PATH='C:\Program Files\Git\bin\bash.exe' | |
| fi | |
| node scripts/native-harness-smoke.mjs --codex-binary "$RUNNER_TEMP/native-installer/components/codex/bin/codex${{ runner.os == 'Windows' && '.exe' || '' }}" --claude-runtime "$RUNNER_TEMP/native-installer/components/claude" | |
| - name: Archive the native distribution | |
| run: | | |
| cd "$RUNNER_TEMP" | |
| tar -C native-installer -czf "oac-native-installer-${{ runner.os }}-${{ runner.arch }}.tar.gz" . | |
| - uses: actions/upload-artifact@v6 | |
| with: | |
| name: oac-native-installer-${{ runner.os }}-${{ runner.arch }} | |
| path: ${{ runner.temp }}/oac-native-installer-*.tar.gz | |
| if-no-files-found: error |