from urllib.request import urlopen
from pathlib import Path
import base64,hashlib,json
base='https://modulo-circuits.the-colony.cc/'
manifest=json.load(urlopen(base+'modulo.json'))
data=b''.join(base64.b64decode(json.load(urlopen(base+p)),validate=True) for p in manifest['parts'])
assert hashlib.sha256(data).hexdigest()=='c455fb0f333d35ab6c81b5edad66c47c5faef933772e3c1a28f6c59f7e693caf'
Path(manifest['filename']).write_bytes(data)
