Repository navigation
fix: remove unused redact_paths param from bug_report - #9651
Merged
Merged
Conversation
bug_report() accepted redact_paths but never read it, and the report has no paths to redact. Also drop "paths" from the docstring line that said the report prints them, so it matches the printed NOTES line. Closes #9644
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
sy.bug_report(redact_paths=True), we previously accepted the parameter, documented it as "redact user-specific paths", and then never read it. The report has no paths to redact. Nowbug_report()no longer takesredact_paths; passing it raises aTypeError.bug_report()docstring, it previously said the report "prints only versions, paths, and config metadata", while the NOTES line the report prints says it contains no paths. Now the docstring says versions and config metadata only, with no tokens, secrets, paths, or PII, which matches the NOTES line.Closes #9644. This replaces #9650, which kept
redact_pathsas a parameter that does nothing.Guidelines
High level
redact_pathsparameter frombug_report()and fixes its docstringMid level
sy.bug_report(redact_paths=...), that did nothingLow level
Security
No change. The report already contained no paths; this only removes a parameter that suggested a redaction pass ran.
Testing
git grep redact_pathsfinds no other uses in the repo.sy.bug_report(as_dict=True)locally; it returns the full report.pre-commit run --all-filespasses.Asana task