Files
PaperClipAI/server/src/__tests__
DottaandClaude Opus 5.5 febf2b81a1 fix(telemetry): read each Composio app's outcome and keep links from partial checks
Greptile review: an agent's COMPOSIO_MANAGE_CONNECTIONS add gave every
requested app the same outcome, so an app that was already connected
could be counted as needs_auth, and a response with no result for an
app as succeeded. Read each app's own result with
composioAppSetupResult instead: connected is succeeded, a sign-in link
is needs_auth, and an error or a missing result is failed.

The Composio list check also emitted connection.app_linked only after
the whole batch. A later app that failed in the same check skipped the
event for apps already saved as connected, and the next check saw them
as already connected. Emit right after each committed row.

Tested: connector-telemetry unit tests (mixed per-app outcomes, error
and empty responses) and a composio-app-setup case where a later app
fails after an earlier app is saved as connected.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-23 10:39:49 -06:00
..
…

Server Tests

Server tests that need a real PostgreSQL process must use ./helpers/embedded-postgres.ts instead of constructing embedded-postgres directly.

The shared helper creates a throwaway data directory and a reserved-safe loopback port for each test database. This protects the live Paperclip control-plane Postgres from server vitest runs; see PAP-2033 for the incident that introduced this guard.