Skip to content

Fix remote ops production smoke startup - #130

Merged
delete-cloud merged 1 commit into
mainfrom
feat/remote-ops-smoke
May 11, 2026
Merged

delete-cloud merged 1 commit into
mainfrom
feat/remote-ops-smoke

Conversation

@delete-cloud

@delete-cloud delete-cloud commented May 10, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • defer coding_agent.ui HTTP server imports so serve --config initializes production cloud workspace config before the global session manager is built
  • add a cold-import regression test for python -m coding_agent
  • document Remote Operations CLI usage and a production smoke checklist

Validation

  • production smoke with real Docker workspace and DeepSeek deepseek-v4-flash: /readyz OK, remote run created REMOTE_MARKER.txt, archive manifest/download restored it locally, session cleanup left no sessions/workspaces
  • uv run pytest tests/ui/test_http_server.py::test_cli_module_import_does_not_eagerly_import_http_server tests/cli/test_remote_client.py -q
  • uv run pytest tests/ui/test_http_server.py tests/ui/test_execution_binding.py tests/ui/test_http_server_workspace_transfer.py -q
  • uv run basedpyright src/coding_agent/ui/init.py
  • git diff --check

Summary by CodeRabbit

Release Notes

  • Documentation
    • Enhanced Remote Operations CLI documentation with configuration guidance, workflow execution, and session management procedures.
    • Added Production Smoke validation procedure for verifying production startup, readiness, and workflow execution integrity.

Review Change Stack

@coderabbitai

coderabbitai Bot commented May 10, 2026 •

Copy link
Copy Markdown
Contributor

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 5d68ebe4-7192-4c7e-885d-cf794d04edfa

📥 Commits

Reviewing files that changed from the base of the PR and between 056d040 and ab6342d.

📒 Files selected for processing (3)
  • coding-agent/docs/remote-sandbox-production.md
  • coding-agent/src/coding_agent/ui/__init__.py
  • coding-agent/tests/ui/test_http_server.py

📝 Walkthrough

Walkthrough

This PR restructures the coding_agent.ui module to defer http_server initialization via lazy attribute loading, validates the pattern with import-isolation tests, and documents remote operations CLI procedures including endpoint setup, one-shot workflows, session management, and production smoke validation.

Changes

Lazy Import Pattern and Production Operations

Layer / File(s) Summary
Public API Contract
coding-agent/src/coding_agent/ui/__init__.py
__all__ now exports only HeadlessConsumer and RichConsumer; app and wait_for_approval are removed from explicit exports.
Lazy Loading Implementation
coding-agent/src/coding_agent/ui/__init__.py
Module-level __getattr__ lazily imports http_server and returns app or wait_for_approval on access, deferring initialization until needed.
Import Behavior Validation Tests
coding-agent/tests/ui/test_http_server.py
Subprocess import check and updated test cleanup confirm that importing coding_agent.__main__ does not eagerly load http_server; module-state restoration ensured.
Remote Operations and Production Validation
coding-agent/docs/remote-sandbox-production.md
New Remote Operations CLI section covers endpoint setup, remote run/remote repl workflows, session/workspace commands, and token scopes; Production Smoke checklist validates startup, readiness, execution, and cleanup.

Possibly related PRs

Poem

🐰 The module once eager, now learns to delay,
Lazy imports bloom when the user will play,
Remote operations guide the sandbox to shine,
Production smoke swirls through the validation line,
Efficiency hops forward—one test at a time!

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Fix remote ops production smoke startup' refers to the primary objective described in the PR—deferring HTTP server imports to fix production cloud workspace initialization—which is a real and significant part of the changeset.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/remote-ops-smoke

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@delete-cloud
delete-cloud merged commit 62792ea into main May 11, 2026
1 check passed
@delete-cloud
delete-cloud deleted the feat/remote-ops-smoke branch May 11, 2026 02:42
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.

1 participant