-
Notifications
You must be signed in to change notification settings - Fork 11
Remove redundant log message #149
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
Conversation
|
Related: |
|
Explain why redundant, with screenshot or example? |
|
This log message is prone to too much repetition. Logging with the name of the shelf is enough. No need to repeat messages about every shelf with similar name found like: |
| .first() is None | ||
|
|
||
| if not is_shelf_name_unique: | ||
| log.error("A public shelf with the name '{}' already exists.".format(title)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any chance the line should be commented out and clarified, e.g. as follows?
# log.info("A public shelf with similar name '{}' already exists.".format(title))
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
cps/shelf.py
Outdated
|
|
||
| if not is_shelf_name_unique: | ||
| log.error("A public shelf with the name '{}' already exists.".format(title)) | ||
| # log.error("A public shelf with the name '{}' already exists.".format(title)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| # log.error("A public shelf with the name '{}' already exists.".format(title)) | |
| # log.info("A public shelf with similar name '{}' already exists.".format(title)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok?
Co-authored-by: A Holt <[email protected]>
No description provided.