Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cider-inspector-inspect-last-exception should inspect specific exceptions, not the last one #3610

Open
vemv opened this issue Jan 21, 2024 · 3 comments
Assignees

Comments

@vemv
Copy link
Member

vemv commented Jan 21, 2024

cider-inspector-inspect-last-exception is meant to inspect the exception of the current stacktrace, as stored in *e.

However *e can sometimes store a different exception. I experienced it the other day for a contrived scenario (hitting my server with clj-http from the server's repl - so an exception would be thrown both in the server, and the repl - both in the same JVM).

Most times things work as intended, but using a more accurate means than last would result in better reliability.

Worth noting that there's "analyze-last-stacktrace" and "analyze-stacktrace". I made the mistake of introducing a "inspect-last-exception op - should have been "inspect-exception" accepting an argument.

@vemv vemv self-assigned this Jan 21, 2024
@bbatsov
Copy link
Member

bbatsov commented Jan 23, 2024

I'll have to look into the issue at hand, but in general for me it makes a lot of sense to have analyze/inspect-last-* and analyze/inspect-*, as having to constantly select what to operate on is a bit time consuming. It should always be an option, but some shortcuts for common scenarios make sense.

@vemv
Copy link
Member Author

vemv commented Jan 23, 2024

Agreed. The original op can be handy as an interactive helper.

@bbatsov
Copy link
Member

bbatsov commented Jan 23, 2024

Yeah, exactly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants