Skip to content
This repository has been archived by the owner on Aug 17, 2023. It is now read-only.

Syntax error in utils.py #6

Open
fatmeat opened this issue Jun 21, 2022 · 5 comments
Open

Syntax error in utils.py #6

fatmeat opened this issue Jun 21, 2022 · 5 comments

Comments

@fatmeat
Copy link

fatmeat commented Jun 21, 2022

Describe the bug
Syntax error in utils.py

Screenshots
PS D:\Github\check_rep> python .\check_rep.py -q x.x.x.x
Traceback (most recent call last):
File ".\check_rep.py", line 12, in
from core.geomap import map_free_geo, multi_map
File "D:\Github\check_rep\core\geomap.py", line 10, in
from core.utils import DOMAIN, IP, Helpers, Workers, logger
File "D:\Github\check_rep\core\utils.py", line 192
if match := re.findall(self.query, req.text):
^
SyntaxError: invalid syntax

Desktop (please complete the following information):
OS: Windows

@dfirsec
Copy link
Owner

dfirsec commented Jun 23, 2022

What version of Python are you using? Thanks!

@AkhilNagaaroor
Copy link

I came across the same issue on Centos 7 with Python3 :-

Traceback (most recent call last): File "check_rep.py", line 12, in <module> from core.geomap import map_free_geo, multi_map File "/root/check_rep/core/geomap.py", line 11, in <module> from core.utils import DOMAIN, IP, Helpers, Workers, logger File "/root/check_rep/core/utils.py", line 191 if match := re.findall(self.query, req.text): ^ SyntaxError: invalid #syntax

@dfirsec
Copy link
Owner

dfirsec commented Jun 29, 2022

I've corrected the code and replaced the named expression (Python 3.8 feature.)

@AkhilNagaaroor
Copy link

Thanks. That error was fixed but I'm getting another error :-

Traceback (most recent call last): File "check_rep.py", line 14, in <module> from core.vt_check import VirusTotalChk File "/root/check_rep/core/vt_check.py", line 48 if json_resp := json.loads(data): ^ SyntaxError: invalid syntax

@dfirsec
Copy link
Owner

dfirsec commented Jun 29, 2022

Issue resolved; replaced the named expression json_resp := json.loads(data):.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants