Commit 44a3326
fix: Don't cache timeout/error results in LeanProver (#5)
* fix: Don't cache timeout/error results in LeanProver
Only cache results from successful lean invocations (success or
type-check failure). Timeout and unexpected errors are transient and
should not permanently prevent retries for the same spec.
Matches CoqProver behavior where cache.put is inside the try block.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* fix: Move cache.put after try/except to avoid swallowing valid results
cache.put inside try was covered by the broad except Exception,
meaning a cache error would discard a valid proof result and return
INCONCLUSIVE. Since both except branches return early, cache.put
safely goes after the try/except block — only reached with a valid
result from _run_lean.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>1 parent 73c3128 commit 44a3326
1 file changed
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
114 | 114 | | |
115 | 115 | | |
116 | 116 | | |
117 | | - | |
| 117 | + | |
118 | 118 | | |
119 | 119 | | |
120 | 120 | | |
| |||
126 | 126 | | |
127 | 127 | | |
128 | 128 | | |
129 | | - | |
| 129 | + | |
130 | 130 | | |
131 | 131 | | |
132 | 132 | | |
| |||
0 commit comments