You're right about passing such errors up to the language binding.
On Sun, Feb 16, 2014 at 3:05 PM, Goswin von Brederlow <[email protected]> wrote: > On Fri, Feb 14, 2014 at 10:26:10AM +0100, Pieter Hintjens wrote: >> On Wed, Feb 12, 2014 at 9:25 AM, Laurent Alebarde <[email protected]> wrote: >> >> > If the answer is positive, I think it should assert as soon as the >> > socket binds or connects to a none tcp address. >> > >> > Please don't assert. return an error. An application can never handle >> > an assert and give a good error, like e.g "Wrong transport type >> > specified in conffile". >> >> You can't sensibly be specifying tcp vs. inproc in a conffile... it's >> too intimately tied to the architecture. Especially when using STREAM >> sockets. I'd rather see a LOLRTFM assert when people do impossible API >> calls. >> >> -Pieter > > Think about what that means for debugging such a problem. E.g in > python an assert will kill the whole python interpreter showing you > the file and line of the C file in limbzmq where the assertion is. On > the other hand an error can raise an exception in python and give you > the file and line where the bad API call is made. > > I find the later far more usefull. > > MfG > Goswin > _______________________________________________ > zeromq-dev mailing list > [email protected] > http://lists.zeromq.org/mailman/listinfo/zeromq-dev _______________________________________________ zeromq-dev mailing list [email protected] http://lists.zeromq.org/mailman/listinfo/zeromq-dev
