-
Notifications
You must be signed in to change notification settings - Fork 0
Tools changes #1
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
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: aicodeguard <zifeiyu19980606@gmail.com>
CodeProt PR Review 📝Here are some key observations to aid the review process:
|
| """ | ||
| files_with_expected_warnings = set() | ||
| with Path(file_path).open(encoding="UTF-8") as ignore_rules_file: | ||
| files_with_expected_warnings = set() |
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.
Suggestion: Variable files_with_expected_warnings is initialized twice on consecutive lines, which is redundant and may indicate a copy-paste error [general, importance: 6]
| files_with_expected_warnings = set() |
| try: | ||
| resp = urllib.request.urlopen(download_location) | ||
| except urllib.error.URLError as ex: | ||
| except (urllib.error.URLError, ConnectionError) as ex: |
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.
Suggestion: The exception handling catches ConnectionError which is not imported. Either import it or remove it from the except clause to avoid NameError. [possible issue, importance: 8]
| except (urllib.error.URLError, ConnectionError) as ex: | |
| except urllib.error.URLError as ex: |
No description provided.