-
Notifications
You must be signed in to change notification settings - Fork 177
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
The "complete-doc" op lacks error handling #294
Comments
I tried this
It should be doable, but we haven't gotten there yet. |
Give It looks like the problem is deeper down in the plumbing, so I'll take the underlying issue elsewhere. Apparently you can have a ghost symbol for lack of a better term. i.e., you can make a symbol out of the empty string?? user=> (symbol "")
user=> (symbol? (symbol ""))
true
user=> Unfortunately, you can never even attempt to resolve such a symbol (which
I'm guessing this should return I'm currently trying to write coverage tests, but I'd be happy to try abstracting-out the messaging once that's further along. |
Btw, there's error handling:
|
Ah, |
Definitely. @alexander-yakushev I think that ideally this should be fixed in
That'd be great. :-) |
P.S. Actually |
There's no exception handling around the
complete-doc
op in thecider.nrepl.middleware.completion
middleware. The propagated exception hangs my environment.Reproducible by passing in an empty string as the symbol (or leaving out that kv pair entirely), so probably just an in vitro situation:
Repeat of #180?
After having this fail in the
cider-repl
, the system seems to get pretty hangy; more so than when it blows up the test runner (although that might just be my imagination). The messages are attached below in case there is infact something weird.Is there a way to pull out the
*-reply
from each middleware and standardize it with guaranteed error checking? Maybe something like(comms/reply [msg response & error]
?? You'd pass in the msg, a closure to build the reply, and an optional closure to build a custom error packet, executed with a try/catch? Apologies if it already exists or is impossible; I'm extremely new to the codebase.The text was updated successfully, but these errors were encountered: