fix: QC-Ratings aus 7 älteren Artikeln entfernt (CHECK 10)
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
import sys, re, gzip
|
||||
|
||||
data = sys.stdin.buffer.read()
|
||||
if data[:2] == b'\x1f\x8b':
|
||||
data = gzip.decompress(data)
|
||||
|
||||
text = data.decode('utf-8', errors='replace')
|
||||
|
||||
links = re.findall(r'<a[^>]*href="(/[^"]+)"[^>]*>([^<]{15,200})</a>', text)
|
||||
for url, title in links[:30]:
|
||||
clean = title.strip()
|
||||
if any(kw in url.lower() for kw in ['board','game','tabletop']):
|
||||
u = 'https://www.polygon.com' + url
|
||||
print(f'TITLE: {clean}')
|
||||
print(f'URL: {u}')
|
||||
print()
|
||||
Reference in New Issue
Block a user