Skip to content

Commit

Permalink
Fixed validate file logic errors
Browse files Browse the repository at this point in the history
  • Loading branch information
qing762 committed Feb 4, 2024
1 parent 090b067 commit da74751
Showing 1 changed file with 20 additions and 4 deletions.
24 changes: 20 additions & 4 deletions lib/validate.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,27 @@


async def lintCheck():
subprocess.run("flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics")
subprocess.run(
"flake8 . --count --exit-zero --max-complexity=15 --max-line-length=300 --statistics"
[
"flake8",
".",
"--count",
"--select=E9,F63,F7,F82",
"--show-source",
"--statistics",
]
)
subprocess.run(
[
"flake8",
".",
"--count",
"--exit-zero",
"--max-complexity=15",
"--max-line-length=300",
"--statistics",
]
)
return


async def validateLinks():
Expand Down Expand Up @@ -40,7 +56,7 @@ async def validateLinks():
for url in urls:
async with session.get(url) as response:
if response.status == 200:
print(f"0")
print("0")
else:
print(f"Link is invalid: {url}")
all_links_valid = False
Expand Down

0 comments on commit da74751

Please sign in to comment.