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
In every Python version that I've tested, writing a config.ini file (utilizing configparser.ConfigParser), the result is such that the config.ini file has 2 newlines at the end of the file.
The problem is that source code editors like Sublime Text, or IDEs like PyCharm, already insert a newline at the end of a file, but then configparser.ConfigParser
(or maybe the Python's write() function?) insert its own as well.
Looks like the same as bpo-32917. I presume there are two newlines at the end of the file because there are two newlines following every config section.
IMO this is a minor cosmetic annoyance, just like writing a key with an empty value gets you a trailing space after the equals sign at the end of the line. Not worth changing as a bug fix, and not worth a special option, but maybe okay to change if the code is simple and it doesn't harm compatibility.
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: