Conversation
There was a problem hiding this comment.
Click here to look at the relevant links ⬇️
🔗 Relevant Links
Repository:
Python:
Automated review generated by algorithms-keeper. If there's any problem regarding this review, please open an issue about it.
algorithms-keeper commands and options
algorithms-keeper actions can be triggered by commenting on this PR:
@algorithms-keeper reviewto trigger the checks for only added pull request files@algorithms-keeper review-allto trigger the checks for all the pull request files, including the modified files. As we cannot post review comments on lines not part of the diff, this command will post all the messages in one comment.NOTE: Commands are in beta and so this feature is restricted only to a member or owner of the organization.
for more information, see https://pre-commit.ci
| else: | ||
| try: | ||
| IP(x) | ||
| except: |
| x = input() | ||
| try: | ||
| IP(x) | ||
| except: |
There was a problem hiding this comment.
IPy literally works that way. I can easily fix it with
except Exception as ex:
print('Failed \n" + ex + 'Finishing \n")
There was a problem hiding this comment.
There was a problem hiding this comment.
Got it. I can fix it by using logging module. What should i do next?
There was a problem hiding this comment.
Click details next to each of the failing ❌ tests below and try to get them to be green ✅
added logging for exceptions, fixed invalid var name,
There was a problem hiding this comment.
Click here to look at the relevant links ⬇️
🔗 Relevant Links
Repository:
Python:
Automated review generated by algorithms-keeper. If there's any problem regarding this review, please open an issue about it.
algorithms-keeper commands and options
algorithms-keeper actions can be triggered by commenting on this PR:
@algorithms-keeper reviewto trigger the checks for only added pull request files@algorithms-keeper review-allto trigger the checks for all the pull request files, including the modified files. As we cannot post review comments on lines not part of the diff, this command will post all the messages in one comment.NOTE: Commands are in beta and so this feature is restricted only to a member or owner of the organization.
for more information, see https://pre-commit.ci
added type-hints, fixed var name
There was a problem hiding this comment.
Click here to look at the relevant links ⬇️
🔗 Relevant Links
Repository:
Python:
Automated review generated by algorithms-keeper. If there's any problem regarding this review, please open an issue about it.
algorithms-keeper commands and options
algorithms-keeper actions can be triggered by commenting on this PR:
@algorithms-keeper reviewto trigger the checks for only added pull request files@algorithms-keeper review-allto trigger the checks for all the pull request files, including the modified files. As we cannot post review comments on lines not part of the diff, this command will post all the messages in one comment.NOTE: Commands are in beta and so this feature is restricted only to a member or owner of the organization.
Fixed type hint
Fixed type hints, and list creation err
There was a problem hiding this comment.
Click here to look at the relevant links ⬇️
🔗 Relevant Links
Repository:
Python:
Automated review generated by algorithms-keeper. If there's any problem regarding this review, please open an issue about it.
algorithms-keeper commands and options
algorithms-keeper actions can be triggered by commenting on this PR:
@algorithms-keeper reviewto trigger the checks for only added pull request files@algorithms-keeper review-allto trigger the checks for all the pull request files, including the modified files. As we cannot post review comments on lines not part of the diff, this command will post all the messages in one comment.NOTE: Commands are in beta and so this feature is restricted only to a member or owner of the organization.
| @@ -0,0 +1,122 @@ | |||
| ###################################### | |||
There was a problem hiding this comment.
An error occurred while parsing the file: other/blacklistipchecker.py
Traceback (most recent call last):
File "/opt/render/project/src/algorithms_keeper/parser/python_parser.py", line 146, in parse
reports = lint_file(
^^^^^^^^^^
libcst._exceptions.ParserSyntaxError: Syntax Error @ 1:1.
tokenizer error: unterminated string literal
######################################
^Fixed bunch of hasher in the beginning of file
for more information, see https://pre-commit.ci
Removed e-mail functionality to pass tests
for more information, see https://pre-commit.ci
Fixed deprecated type hints, sorted imports
for more information, see https://pre-commit.ci
Sorted imports with isort
for more information, see https://pre-commit.ci
Fixed some types mismatch
Co-authored-by: Christian Clauss <cclauss@me.com>
There was a problem hiding this comment.
Click here to look at the relevant links ⬇️
🔗 Relevant Links
Repository:
Python:
Automated review generated by algorithms-keeper. If there's any problem regarding this review, please open an issue about it.
algorithms-keeper commands and options
algorithms-keeper actions can be triggered by commenting on this PR:
@algorithms-keeper reviewto trigger the checks for only added pull request files@algorithms-keeper review-allto trigger the checks for all the pull request files, including the modified files. As we cannot post review comments on lines not part of the diff, this command will post all the messages in one comment.NOTE: Commands are in beta and so this feature is restricted only to a member or owner of the organization.
| link = f"https://api.blacklistchecker.com/check/{ip}" | ||
| result = requests.get(link, auth=(api_key, "") | ||
| result_dec = json.loads(result.content) | ||
| print(result_dec) |
There was a problem hiding this comment.
An error occurred while parsing the file: other/blacklistipchecker.py
Traceback (most recent call last):
File "/opt/render/project/src/algorithms_keeper/parser/python_parser.py", line 146, in parse
reports = lint_file(
^^^^^^^^^^
libcst._exceptions.ParserSyntaxError: Syntax Error @ 20:16.
parser error: error at 19:15: expected one of !=, %, &, (, *, **, +, ,, -, ., /, //, <, <<, <=, ==, >, >=, >>, @, [, ^, and, if, in, is, not, or, |
print(result_dec)
^Co-authored-by: Christian Clauss <cclauss@me.com>
There was a problem hiding this comment.
Click here to look at the relevant links ⬇️
🔗 Relevant Links
Repository:
Python:
Automated review generated by algorithms-keeper. If there's any problem regarding this review, please open an issue about it.
algorithms-keeper commands and options
algorithms-keeper actions can be triggered by commenting on this PR:
@algorithms-keeper reviewto trigger the checks for only added pull request files@algorithms-keeper review-allto trigger the checks for all the pull request files, including the modified files. As we cannot post review comments on lines not part of the diff, this command will post all the messages in one comment.NOTE: Commands are in beta and so this feature is restricted only to a member or owner of the organization.
| link = f"https://api.blacklistchecker.com/check/{ip}" | ||
| result = requests.get(link, auth=(api_key, "") | ||
| result_dec = json.loads(result.content) | ||
| print(result_dec) |
There was a problem hiding this comment.
An error occurred while parsing the file: other/blacklistipchecker.py
Traceback (most recent call last):
File "/opt/render/project/src/algorithms_keeper/parser/python_parser.py", line 146, in parse
reports = lint_file(
^^^^^^^^^^
libcst._exceptions.ParserSyntaxError: Syntax Error @ 20:16.
parser error: error at 19:15: expected one of !=, %, &, (, *, **, +, ,, -, ., /, //, <, <<, <=, ==, >, >=, >>, @, [, ^, and, if, in, is, not, or, |
print(result_dec)
^missing ")"
There was a problem hiding this comment.
Click here to look at the relevant links ⬇️
🔗 Relevant Links
Repository:
Python:
Automated review generated by algorithms-keeper. If there's any problem regarding this review, please open an issue about it.
algorithms-keeper commands and options
algorithms-keeper actions can be triggered by commenting on this PR:
@algorithms-keeper reviewto trigger the checks for only added pull request files@algorithms-keeper review-allto trigger the checks for all the pull request files, including the modified files. As we cannot post review comments on lines not part of the diff, this command will post all the messages in one comment.NOTE: Commands are in beta and so this feature is restricted only to a member or owner of the organization.
| detects = "!" | ||
| return (res, detects) | ||
| else result_dec.get("detections") != 0: | ||
| res = ip |
There was a problem hiding this comment.
An error occurred while parsing the file: other/blacklistipchecker.py
Traceback (most recent call last):
File "/opt/render/project/src/algorithms_keeper/parser/python_parser.py", line 146, in parse
reports = lint_file(
^^^^^^^^^^
libcst._exceptions.ParserSyntaxError: Syntax Error @ 26:17.
parser error: error at 25:19: expected :
res = ip
^added missing rightside comparison agrument
Changed var type
added type-hints
for more information, see https://pre-commit.ci
fixed double var definition
|
Who can review this PR? @cclauss help please |
|
This is a how-to-use, not an algorithm as discussed in CONTRIBUTING.md |
Describe your change:
Checklist: