Commit 3614c96
fix: add weakref callback to clean up resolve cache entries
The cache used dict keyed by id(doc) with no cleanup, causing a slow
memory leak in long-running processes. Added a weakref finalizer
callback that removes the cache entry when the doc is garbage
collected.
Fixes ISSUES.md #27.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>1 parent 87f7e69 commit 3614c96
1 file changed
+5
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
228 | 228 | | |
229 | 229 | | |
230 | 230 | | |
231 | | - | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
232 | 236 | | |
233 | 237 | | |
234 | 238 | | |
| |||
0 commit comments