Zulip Chat Archive
Stream: lean4
Topic: Figuring out the source of `sorryAx` in a `#print axioms`
Alex Keizer (Aug 20 2025 at 11:05):
I'm currently looking at the result of a #print axioms foo, which I expected to be sorry-free, and am unfortunately met with the fact it does rely on sorry somewhere. So far I've just been going recursively through the theorems, and printing the axioms of all potentially suspect lemmas it uses untill I found the culprit, but this is in a fairly large project, so I wondered if there is some automated way of finding out exactly which lemma introduces the sorry?
Leni Aniva (Aug 20 2025 at 11:21):
you can always #eval and use a snippet to iterate over the deps of a theorem
Julian Berman (Aug 20 2025 at 11:48):
I think @Aaron Hill mentioned a rumor that @Yaël Dillies has something for this, a #track_sorry command, but GitHub search and Zulip search are both being poor and not showing me where it comes from.
Bryan Gin-ge Chen (Aug 20 2025 at 11:52):
Probably #25179? The PR description there also links to the following Zulip threads:
- #Is there code for X? > Hunting down axioms
- #Is there code for X? > ✔ Finding usages of `sorry` in external code @ 💬
Alex Keizer (Aug 20 2025 at 11:52):
I've found the sorry manually for now, but if this command exists, I'd love to know where it lives for next time
Geoffrey Irving (Aug 20 2025 at 11:52):
#track_native would also be super cool.
Last updated: Dec 20 2025 at 21:32 UTC