Commit f92095e
committed
fix(mcp): purge stale closets on drawer update and delete
Closets are mined once from a source file's content and only rebuilt by
re-mining that file. tool_update_drawer and tool_delete_drawer never
touched them, so a corrected or deleted drawer left a closet quoting the
old text indefinitely, and search boosts ranking by source_file, so a
stale closet could outrank the corrected drawer.
Purge the matching source's closets through _purge_source_closets, the
helper delete_by_source already uses for this reason. update_drawer
purges only when content changes; a wing/room move alone leaves the
quoted text correct.
Fixes #23251 parent 88247ac commit f92095e
3 files changed
Lines changed: 93 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| 14 | + | |
14 | 15 | | |
15 | 16 | | |
16 | 17 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3218 | 3218 | | |
3219 | 3219 | | |
3220 | 3220 | | |
3221 | | - | |
| 3221 | + | |
| 3222 | + | |
| 3223 | + | |
| 3224 | + | |
| 3225 | + | |
| 3226 | + | |
| 3227 | + | |
| 3228 | + | |
| 3229 | + | |
| 3230 | + | |
| 3231 | + | |
3222 | 3232 | | |
3223 | 3233 | | |
3224 | 3234 | | |
3225 | 3235 | | |
3226 | 3236 | | |
3227 | 3237 | | |
| 3238 | + | |
3228 | 3239 | | |
3229 | 3240 | | |
3230 | 3241 | | |
| |||
3833 | 3844 | | |
3834 | 3845 | | |
3835 | 3846 | | |
| 3847 | + | |
| 3848 | + | |
| 3849 | + | |
| 3850 | + | |
| 3851 | + | |
| 3852 | + | |
| 3853 | + | |
3836 | 3854 | | |
3837 | 3855 | | |
3838 | 3856 | | |
| |||
3862 | 3880 | | |
3863 | 3881 | | |
3864 | 3882 | | |
| 3883 | + | |
3865 | 3884 | | |
3866 | 3885 | | |
3867 | 3886 | | |
| |||
3879 | 3898 | | |
3880 | 3899 | | |
3881 | 3900 | | |
| 3901 | + | |
3882 | 3902 | | |
3883 | 3903 | | |
3884 | 3904 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2227 | 2227 | | |
2228 | 2228 | | |
2229 | 2229 | | |
| 2230 | + | |
| 2231 | + | |
| 2232 | + | |
| 2233 | + | |
| 2234 | + | |
| 2235 | + | |
| 2236 | + | |
| 2237 | + | |
| 2238 | + | |
| 2239 | + | |
| 2240 | + | |
| 2241 | + | |
| 2242 | + | |
| 2243 | + | |
| 2244 | + | |
| 2245 | + | |
| 2246 | + | |
| 2247 | + | |
| 2248 | + | |
| 2249 | + | |
| 2250 | + | |
| 2251 | + | |
| 2252 | + | |
| 2253 | + | |
| 2254 | + | |
2230 | 2255 | | |
2231 | 2256 | | |
2232 | 2257 | | |
| |||
2880 | 2905 | | |
2881 | 2906 | | |
2882 | 2907 | | |
| 2908 | + | |
| 2909 | + | |
| 2910 | + | |
| 2911 | + | |
| 2912 | + | |
| 2913 | + | |
| 2914 | + | |
| 2915 | + | |
| 2916 | + | |
| 2917 | + | |
| 2918 | + | |
| 2919 | + | |
| 2920 | + | |
| 2921 | + | |
| 2922 | + | |
| 2923 | + | |
| 2924 | + | |
| 2925 | + | |
| 2926 | + | |
| 2927 | + | |
| 2928 | + | |
| 2929 | + | |
| 2930 | + | |
| 2931 | + | |
| 2932 | + | |
| 2933 | + | |
| 2934 | + | |
| 2935 | + | |
| 2936 | + | |
| 2937 | + | |
| 2938 | + | |
| 2939 | + | |
| 2940 | + | |
| 2941 | + | |
| 2942 | + | |
| 2943 | + | |
| 2944 | + | |
| 2945 | + | |
| 2946 | + | |
| 2947 | + | |
| 2948 | + | |
| 2949 | + | |
| 2950 | + | |
| 2951 | + | |
| 2952 | + | |
| 2953 | + | |
2883 | 2954 | | |
2884 | 2955 | | |
2885 | 2956 | | |
| |||
0 commit comments