diff options
-rw-r--r-- | paramiko/util.py | 2 | ||||
-rw-r--r-- | sites/www/changelog.rst | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/paramiko/util.py b/paramiko/util.py index 5ad1e3fd..b69e8882 100644 --- a/paramiko/util.py +++ b/paramiko/util.py @@ -241,7 +241,7 @@ def log_to_file(filename, level=DEBUG): if len(l.handlers) > 0: return l.setLevel(level) - f = open(filename, 'w') + f = open(filename, 'a') lh = logging.StreamHandler(f) lh.setFormatter(logging.Formatter('%(levelname)-.3s [%(asctime)s.%(msecs)03d] thr=%(_threadid)-3d %(name)s: %(message)s', '%Y%m%d-%H:%M:%S')) diff --git a/sites/www/changelog.rst b/sites/www/changelog.rst index 10419f5c..9ce03fdc 100644 --- a/sites/www/changelog.rst +++ b/sites/www/changelog.rst @@ -2,6 +2,8 @@ Changelog ========= +* :bug:`683` Make `util.log_to_file()` append instead of replace. Thanks + to ``@vlcinsky`` for the report. * :release:`2.1.2 <2017-02-20>` * :release:`2.0.5 <2017-02-20>` * :release:`1.18.2 <2017-02-20>` |