Conversation
…RL priority chain - Extract config resolution logic into resolvePostgresClientConfig() so the URL priority chain can be tested directly without mocking - Rewrite URL priority tests to assert the resolved URL value instead of just checking that db is defined - Add tests for DATABASE_URL fallback, config forwarding, and non-mutation of the original connection object - Remove duplicate backward-compat tests that were identical to direct usage tests - Make all test callbacks async and await close() to avoid dropped promises
📝 WalkthroughWalkthroughA new internal utility function Changes
🚥 Pre-merge checks | ✅ 1✅ Passed checks (1 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. 🧹 Recent nitpick comments
📜 Recent review detailsConfiguration used: Organization UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (2)
🧰 Additional context used📓 Path-based instructions (6)packages/drizzle/**/*.{ts,tsx}📄 CodeRabbit inference engine (packages/drizzle/AGENTS.md)
Files:
packages/drizzle/**/*.{test,spec}.{ts,tsx}📄 CodeRabbit inference engine (packages/drizzle/AGENTS.md)
Files:
**/*.{ts,tsx,js,jsx,json,md}📄 CodeRabbit inference engine (AGENTS.md)
Files:
**/*.{ts,tsx}📄 CodeRabbit inference engine (AGENTS.md)
Files:
packages/**/*.{ts,tsx}📄 CodeRabbit inference engine (AGENTS.md)
Files:
packages/*/test/**/*.{ts,tsx}📄 CodeRabbit inference engine (AGENTS.md)
Files:
🧠 Learnings (1)📚 Learning: 2025-12-21T00:31:41.858ZApplied to files:
🧬 Code graph analysis (2)packages/drizzle/test/config.test.ts (1)
packages/drizzle/src/postgres.ts (2)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (10)
🔇 Additional comments (1)
✏️ Tip: You can disable this entire section by setting Comment |
📦 Canary Packages Publishedversion: PackagesInstallAdd to your {
"dependencies": {
"@agentuity/server": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-server-1.0.3-b8e5193.tgz",
"@agentuity/auth": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-auth-1.0.3-b8e5193.tgz",
"@agentuity/drizzle": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-drizzle-1.0.3-b8e5193.tgz",
"@agentuity/evals": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-evals-1.0.3-b8e5193.tgz",
"@agentuity/cli": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-cli-1.0.3-b8e5193.tgz",
"@agentuity/workbench": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-workbench-1.0.3-b8e5193.tgz",
"@agentuity/opencode": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-opencode-1.0.3-b8e5193.tgz",
"@agentuity/react": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-react-1.0.3-b8e5193.tgz",
"@agentuity/runtime": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-runtime-1.0.3-b8e5193.tgz",
"@agentuity/postgres": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-postgres-1.0.3-b8e5193.tgz",
"@agentuity/schema": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-schema-1.0.3-b8e5193.tgz",
"@agentuity/frontend": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-frontend-1.0.3-b8e5193.tgz",
"@agentuity/core": "https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-core-1.0.3-b8e5193.tgz"
}
}Or install directly: bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-server-1.0.3-b8e5193.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-auth-1.0.3-b8e5193.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-drizzle-1.0.3-b8e5193.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-evals-1.0.3-b8e5193.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-cli-1.0.3-b8e5193.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-workbench-1.0.3-b8e5193.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-opencode-1.0.3-b8e5193.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-react-1.0.3-b8e5193.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-runtime-1.0.3-b8e5193.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-postgres-1.0.3-b8e5193.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-schema-1.0.3-b8e5193.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-frontend-1.0.3-b8e5193.tgz
bun add https://agentuity-sdk-objects.t3.storageapi.dev/npm/1.0.3-b8e5193/agentuity-core-1.0.3-b8e5193.tgz |
Summary
Follow-up to #889 — addresses review feedback on the drizzle config tests.
resolvePostgresClientConfig()as a pure function so the URL priority chain (connection.url>url>connectionString>DATABASE_URL) can be tested directly without mocking the postgres constructor.urlvalue instead of just checkingdbis defined.DATABASE_URLfallback,urlvsDATABASE_URLprecedence, config forwarding (reconnect,onReconnected), and non-mutation of the original connection object.asyncandawait close()to avoid dropped promises.Summary by CodeRabbit