python 2.7's logging.info(string) and newline characters
Question: Does python 2.7's logging.info(string) (import logging) automatically strip
newline characters from the given string? If not, is there a command to make
it behave like that? If so which command is that?

Thank's a lot!


Answer: No, it will not automatically strip newlines.

You can remove them yourself by calling the `.replace()` method of the string:

    
    
    without_newlines = my_string.replace("\n", "")
    

(Another, slightly more potentially efficient option is to use the deletion
feature of `.translate()`, but `.replace()` may be more readable if you don't
care about high levels of optimization.)

