Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

logging reform: Transport,SFTP* _log() refactor #74

Merged
merged 1 commit into from
Apr 20, 2020
Merged

Conversation

ploxiln
Copy link
Owner

@ploxiln ploxiln commented Mar 29, 2020

Transport._log() does not take msg list, it takes format string

SFTPClient/SFTPServer _log() method does not take msg list
SFTPBase gets new _loglist() method for the rare list case

Transport and SFTP* use proper logging format strings
and separate arguments

SSHClient and AuthHandler always log with single msg string,
so pass to Transport._log() as "%s", msg

get rid of util.tb_strings(), instead _log() with exc_info=True
so that lines of traceback are not separate log messages
(inspired by paramiko#406)

@ploxiln ploxiln force-pushed the logging_reform branch 3 times, most recently from dda756d to 708dcfe Compare April 17, 2020 23:33
Transport._log() does not take msg list, it takes format string

SFTPClient/SFTPServer _log() method does not take msg list
SFTPBase gets new _loglist() method for the rare list case

Transport and SFTP* use proper logging format strings
and separate arguments

SFTPClient no longer needs %% escaping of log messages,
now that it logs correctly

SSHClient and AuthHandler always log with single msg string,
so pass to Transport._log() as "%s", msg

get rid of util.tb_strings(), instead _log() with exc_info=True
so that lines of traceback are not separate log messages
(inspired by paramiko#406)

binascii.hexlify() returns bytes, decode to string for logging
(inspired by paramiko#1661)
@ploxiln ploxiln merged commit fa5f87f into master Apr 20, 2020
@ploxiln ploxiln deleted the logging_reform branch December 20, 2020 03:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant