01-25-2019, 08:06 AM
Thanks a lot. Indeed that was the problem. Now it works as expected.
Thanks for your other comments too.
Re your point of setting the Reply code: Actually I intentionally keep 200 (being "OK"), and only change the text after it to what I want to get. Ideally it shall be "OK<CR><LF>actual response". In the example I have sent I just simplified.
Re your point of Logging vs. Except. Yes, I am aware that Log() is not called if an exception is raised. I have a different (higher severity) Log in the except part too (if OK, I only log in a file, but if an excdeption is raised then I show it on the console too). Again, the example was simplified.
Thanks for your other comments too.
Re your point of setting the Reply code: Actually I intentionally keep 200 (being "OK"), and only change the text after it to what I want to get. Ideally it shall be "OK<CR><LF>actual response". In the example I have sent I just simplified.
Re your point of Logging vs. Except. Yes, I am aware that Log() is not called if an exception is raised. I have a different (higher severity) Log in the except part too (if OK, I only log in a file, but if an excdeption is raised then I show it on the console too). Again, the example was simplified.