You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have updated the Python binding to the latest version of nanomsg today. They do something different than us which is interesting: they raise exceptions when the result from nanomsg is unexpected.
We could have a mode that does the same thing, which could even be the default. It would simplify usage of the lib. For instance, the main loop of the echo server currently looks like this:
Yes. I would not use that style everywhere, sometimes you need fine-grained error handling, this is why I want that as an option. But sometimes you just want things to fail if an error happens. For instance a web application calling a service over nanomsg could log the error and return a generic HTTP 500 error to users.
I have updated the Python binding to the latest version of nanomsg today. They do something different than us which is interesting: they raise exceptions when the result from nanomsg is unexpected.
We could have a mode that does the same thing, which could even be the default. It would simplify usage of the lib. For instance, the main loop of the echo server currently looks like this:
Note that we don't check the result of
nn_shutdown
...With that mode it would look like this:
Thoughts?
EDIT: I can implement it, I just want to know what you think about the idea doing it and submitting a PR.
The text was updated successfully, but these errors were encountered: