-
Notifications
You must be signed in to change notification settings - Fork 633
Enhance the can.logger
to check to see if the log file exists and append if there rather than overwrite
#1326
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
Comments
The Lines 28 to 40 in 0d7f65f
The function call to Line 93 in 0d7f65f
Due to a really excellent Python API implementation, getting the |
@zariiii9003 Given the merge of the new feature provided in #1327, could you please consider the next release to be
I think the easiest way to do this would be to relabel Milestone 4.1.0 to |
I don't mind, but i cannot create releases anyway. I will ask @hardbyte once the other bugfixes are reviewed and merged. |
Is your feature request related to a problem? Please describe.
Consider
can.logger
being used on an embedded Linux system. Apython can.logger ...
process is started as a daemon (/etc/init.d/
) in boot and killed in shutdown. When the system is restarted, the existing log file on the device and its contents is currently overwritten. This results in a loss of data.Describe the solution you'd like
Upon executing
python can.logger ...
the program should check to see if the specified log file exists. If it does exist, then the file should be appended to.Describe alternatives you've considered
An optional argument could be added (perhaps
-a
or-w
) to give the user the option as to whether an existing file, if found, should be overwritten or appended to.Additional context
P.S. Feel free to assign this issue to me. I should be around to it by Sunday or Monday.
The text was updated successfully, but these errors were encountered: