Commit 902ada3
fix: remove duplicate memory_compact registration + redundant schema required (OpenClaw 2026.4.5 compat) (#541)
* fix: remove duplicate memory_compact tool registration in index.ts
memory_compact was registered twice when enableManagementTools is true:
once via registerAllMemoryTools() → registerMemoryCompactTool() in
src/tools.ts, and again in a standalone block in index.ts (lines
2116–2202). OpenClaw 2026.4.5 now throws on duplicate tool name
registration, causing plugin initialization failure.
The standalone block in index.ts is the stale duplicate — the canonical
implementation lives in src/tools.ts and is already wired through
registerAllMemoryTools().
* fix: remove redundant required: ["embedding"] from configSchema root
OpenClaw 2026.4.5 changed how config values are passed to the AJV
validator during framework-level validation. The root-level
required: ["embedding"] constraint fails because the config object
reaching the validator may not have the embedding key at the time of
framework validation (timing/default-handling change).
This constraint was always redundant: the plugin's own
parsePluginConfig() already validates embedding.apiKey presence at
load time, and embedding.required: ["apiKey"] in the sub-schema
still catches misconfiguration.
---------
Co-authored-by: Max Eschbach <maxeschbach@macbookair.local>1 parent aa0d229 commit 902ada3
2 files changed
Lines changed: 1 addition & 92 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2113 | 2113 | | |
2114 | 2114 | | |
2115 | 2115 | | |
2116 | | - | |
2117 | | - | |
2118 | | - | |
2119 | | - | |
2120 | | - | |
2121 | | - | |
2122 | | - | |
2123 | | - | |
2124 | | - | |
2125 | | - | |
2126 | | - | |
2127 | | - | |
2128 | | - | |
2129 | | - | |
2130 | | - | |
2131 | | - | |
2132 | | - | |
2133 | | - | |
2134 | | - | |
2135 | | - | |
2136 | | - | |
2137 | | - | |
2138 | | - | |
2139 | | - | |
2140 | | - | |
2141 | | - | |
2142 | | - | |
2143 | | - | |
2144 | | - | |
2145 | | - | |
2146 | | - | |
2147 | | - | |
2148 | | - | |
2149 | | - | |
2150 | | - | |
2151 | | - | |
2152 | | - | |
2153 | | - | |
2154 | | - | |
2155 | | - | |
2156 | | - | |
2157 | | - | |
2158 | | - | |
2159 | | - | |
2160 | | - | |
2161 | | - | |
2162 | | - | |
2163 | | - | |
2164 | | - | |
2165 | | - | |
2166 | | - | |
2167 | | - | |
2168 | | - | |
2169 | | - | |
2170 | | - | |
2171 | | - | |
2172 | | - | |
2173 | | - | |
2174 | | - | |
2175 | | - | |
2176 | | - | |
2177 | | - | |
2178 | | - | |
2179 | | - | |
2180 | | - | |
2181 | | - | |
2182 | | - | |
2183 | | - | |
2184 | | - | |
2185 | | - | |
2186 | | - | |
2187 | | - | |
2188 | | - | |
2189 | | - | |
2190 | | - | |
2191 | | - | |
2192 | | - | |
2193 | | - | |
2194 | | - | |
2195 | | - | |
2196 | | - | |
2197 | | - | |
2198 | | - | |
2199 | | - | |
2200 | | - | |
2201 | | - | |
2202 | | - | |
2203 | | - | |
2204 | 2116 | | |
2205 | 2117 | | |
2206 | 2118 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
854 | 854 | | |
855 | 855 | | |
856 | 856 | | |
857 | | - | |
858 | | - | |
859 | | - | |
860 | | - | |
| 857 | + | |
861 | 858 | | |
862 | 859 | | |
863 | 860 | | |
| |||
0 commit comments