Repository navigation
Commit 0e90d2f
test(knowledge-pgvector): live PostgreSQL case with no adapter and no requires (#38054)
repo:objectstack#1 · os-elon-musk · session_016WV4cwPhGV4g9p1BGQaZbP
Fixes #38040
## 维护者速读
- 用户无感:只是测试,不改任何运行行为。
- 补上真实 PostgreSQL 上「知识源不写存储、也不声明需要知识服务」这一条的端到端验证,承接知识检索那一组改动。
- 只是新增测试,可直接撤回;已在真实 PostgreSQL 上跑过,去掉新接线的任何一处都会让它变红。
- 需要你做的:无。
## What changes
`capability-mount.live-postgres.test.ts` gains a second block beside the
explicit control: a stack that ships one `knowledge_source` with no
`adapter` and lists no `knowledge` token. It asserts the item alone adds
the token (`stackItemCapabilities` into `resolveServedCapabilities`,
`byItems`), the deployment-store mark is `{ deploymentAdapter:
'pgvector' }` (`resolveCapabilityArgument`), the service mounts and the
store is healthy, passages land in the pgvector tables of the live
schema, and `search_knowledge` returns them with the source id. The
explicit case is unchanged.
## Tests
Live suite on private PostgreSQL 16 + pgvector (UTF8,
`OS_EXPECT_LIVE_DIALECT_MATRIX=1`), head `abf7914641`, under
`os-verify-lock` (`VERDICT command-exit 0`, held 186s, shared box): 1
file, 4/4 passed (2 control, 2 new). Typecheck of `knowledge-pgvector`:
exit 0.
Ablation 1 (`stackItemCapabilities` returns nothing, core rebuilt): the
new block is red, `expected [] to deeply equal ['knowledge']`; the
control passes. Ablation 2 (`resolveCapabilityArgument('knowledge')`
returns no argument, core rebuilt): the new block is red, `expected
undefined to deeply equal { deploymentAdapter: 'pgvector' }`; the
control passes. Restored, core rebuilt (exit 0), final re-run 4/4 green.
In ablation 1 the core d.ts build errored on the mutation's unused
variables (TS6133), but the JS was emitted and the red shows the
mutation was live. Record: comment 7230806559.
## Acceptance notes
overlap-check against origin/main: VERDICT clean exit 0. No source
change; no changeset (test only).
🤖 Generated with [Claude Code](https://claude.com/claude-code)
https://claude.ai/code/session_016WV4cwPhGV4g9p1BGQaZbP
Co-authored-by: os-dev <noreply@anthropic.com>1 parent 7e4df28 commit 0e90d2f
1 file changed
Lines changed: 87 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
12 | 18 | | |
13 | 19 | | |
14 | 20 | | |
15 | | - | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
16 | 29 | | |
17 | 30 | | |
18 | 31 | | |
| |||
83 | 96 | | |
84 | 97 | | |
85 | 98 | | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
0 commit comments