GooseterV / Project-Euler

Re-defined variable from outer scope PYL-W0621
Anti-pattern
Major
a year agoa year old
Redefining name 'DOWNLOADED' from outer scope (line 23)
 9		with open(f"html/p{str(i).zfill(3)}-MINIMAL.html", "w", encoding="utf-8") as pfile:
10			soup = BeautifulSoup(res.text, "html.parser")
11			pfile.write(soup.prettify()) 
12	DOWNLOADED = True_13
14def downloadAll():
15	for i in range(1, 773):
Redefining name 'DOWNLOADED' from outer scope (line 23)
17		with open(f"html/p{str(i).zfill(3)}.html", "w", encoding="utf-8") as pfile:
18			soup = BeautifulSoup(res.text, "html.parser")
19			pfile.write(soup.prettify()) 
20	DOWNLOADED = True_21
22minimal = True
23DOWNLOADED = False