Skip to content

Commit 046aa70

Browse files
committed
update maxTry
1 parent 57c1343 commit 046aa70

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

testProc.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,13 @@
1212
def main() -> None:
1313
pf: whoisdomain.ProcFunc = whoisdomain.ProcFunc()
1414

15+
maxTry = 0
1516
restart_after_count: int = 100
1617
f = pf.makeHandler(whoisdomain.remoteQ2, restart_after_count)
1718

19+
n = 0
1820
for tld in whoisdomain.validTlds():
21+
n += 1
1922
domain = whoisdomain.getTestHint(tld)
2023
domain = domain if domain else f"meta.{tld}"
2124

@@ -24,9 +27,12 @@ def main() -> None:
2427
pc = whoisdomain.ParameterContext()
2528
d = f(domain, pc)
2629
print(d)
30+
2731
except Exception as e:
2832
print(e)
2933

34+
if maxTry and n >= maxTry:
35+
break
3036

3137
if __name__ == "__main__":
3238
main()

0 commit comments

Comments
 (0)