Skip to content

Increase backend test coverage - #15

Merged
samxu01 merged 1 commit into
mainfrom
yz06qi-codex/add-tests-to-increase-coverage
May 28, 2025
Merged

samxu01 merged 1 commit into
mainfrom
yz06qi-codex/add-tests-to-increase-coverage

Conversation

@samxu01

@samxu01 samxu01 commented May 28, 2025

Copy link
Copy Markdown
Contributor

Summary

  • add ability to import migration script without executing it
  • cover DB connection helpers with unit tests
  • cover PG Message model
  • add route unit tests for posts, pods, uploads, pg pods and pg status
  • add migration script tests

Testing

  • npm run lint
  • npm test

@samxu01
samxu01 merged commit c5ddd4a into main May 28, 2025
samxu01 added a commit that referenced this pull request Feb 2, 2026
@samxu01
samxu01 deleted the yz06qi-codex/add-tests-to-increase-coverage branch February 2, 2026 04:36
samxu01 pushed a commit that referenced this pull request Apr 3, 2026
MubaiHua pushed a commit that referenced this pull request Apr 20, 2026
samxu01 added a commit that referenced this pull request May 24, 2026
… all 3 agents

Cron R3 corrects two earlier mis-reads + logs major new findings:

- Theo claimed A+B+D bundle ('I'll take A+B+D as a bundle, and I'll
  coordinate C as a separate openclaw PR/submodule bump'). No code
  pushed yet; workspace-not-git-worktree blocker may still apply.
- Direct mongo query: ALL 3 agents have agentmemories rows. Theo
  (rev=undefined, 2223 chars, 06:18:28Z) and Nova (rev=2, 3148 chars,
  06:30:20Z) wrote via OpenClaw heartbeat-cycle auto-writes; Cody
  (rev=0, 602 chars) via the commonly_save_my_memory MCP tool.
  Phase-4 #11 was wrong — memory IS exercised by all 3, via
  different paths.

Two new Phase-4 findings:

#15: openclaw moltbot memory is heartbeat-only-write, stale during
interactive sessions. Theo/Nova memory contents are heartbeat-cycle
telemetry from 2026-05-20/21, not today's huddle content. Their
chat-turn tool registry doesn't include commonly_save_my_memory.
Possible Commonly improvement: heartbeat cycle should optionally
ingest conversational gravity from recent pod activity into long_term.

#16: shared agent memory may leak routing PII across agents. Nova's
memory contains SamCodexDmPodId — a 1:1 DM pod between Sam and
sam-local-codex. Today agentmemories is per-agent-private so no
leak, but if cross-agent memory ever becomes a collab feature,
routing pointers (DM pod IDs, etc.) need sanitization.

Claude refined Phase-4 #11: 'the commonly_* MCP server loads for
OpenClaw + Codex wrappers but not for Claude wrappers'. Partial
truth — moltbot heartbeat writes work, but moltbot chat-turn
doesn't have the tool either. The Claude-wrapper gap remains.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
samxu01 added a commit that referenced this pull request May 24, 2026
Cron R4 observations:

- Claim collision: Theo and Nova both claimed A+B+D in the same
  minute. Orphan-pattern failure mode — multiple capable agents
  race without coordination, neither ships because each waits for
  the other. Resolved in pod by splitting (Nova→A+B, Theo→D).
- Phase-4 #17 added: agent multi-acknowledgement spam. Theo posted
  4 semantically-identical ack variations within the same minute,
  likely from chat.mention + heartbeat firing concurrent LLM runs.
  No event-dedup or wrapper-side run-in-progress gate.
- Memory observability refresh: Theo's heartbeat-write at 06:48Z
  captured one today-line (board-task work). Nova's heartbeat-write
  at 06:41Z added no today content. Refines Phase-4 #15: heartbeat
  ingestion of pod-conversational-gravity depends on HEARTBEAT.md
  prompt per agent — worth a registry.js audit.

No new code on phase-2/local-dev-parity. 15-min orphan timer set;
if A+B+D doesn't ship by then I scribe + push.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
samxu01 added a commit that referenced this pull request May 24, 2026
…e 2 ~80%

Cron R4 epilogue (stop condition firmly hit):

Cody resolved the Theo+Nova claim collision by shipping all of
Phase 2.A + 2.B + 2.D in a single comprehensive commit 3d398ab
(+812 lines, 4 files) while the others were still acknowledging.

What landed in 3d398ab:
- docker-compose.dev.yml: Dockerfile.commonly → Dockerfile default
  on both clawdbot compose services (Phase 2.B, 2-line change)
- dev.sh: +71 lines — read_env_value / is_truthy_env_value helpers
  + COMMONLY_LOCAL_CLAWDBOT=1 gating on the clawdbot profile (2.A)
- cli/src/commands/dev.js: +593 lines — new `commonly dev clawdbot`
  bootstrap subcommand: login → pod → install moltbot → harvest
  runtime token → write external/clawdbot-state/config/moltbot.json
  with controlUi flag → drop OPENCLAW_USER_TOKEN +
  OPENCLAW_RUNTIME_TOKEN into .env (Phase 2.D)
- cli/__tests__/dev.test.mjs: +148 lines NEW regression test file

Cody's session total: 5 code commits across PR #434 + phase-2.
Theo + Nova: 0 code commits between them.

The standout signal of the session: in this multi-agent setup,
cloud-codex (Cody) is the sole implementer; openclaw moltbots add
review + coordination value but can't ship code today. Captured in
Phase-4 #14 (workspace gap) + #6 + #11 + #15 (tool registry gaps).

Final Phase 2 state:
  ✅ 2.E shipped (3fa0565)
  ✅ 2.A+B+D shipped (3d398ab)
  🟡 2.C openclaw bundled-skills upstream — cross-repo, needs Sam
  📐 ADR-2.F implementation — design complete, code natural-next-sprint

Cron 88af22d0 cancelled. Phase 2 ~80% complete.

Total Phase-4 affordance findings: 17. Memory entries written: 2
(feedback-agents-collab-execute-not-handoff,
feedback-claim-the-orphan-stalled-peer-work).

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
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.

1 participant