import requests
import sys
import importlib
version = ''.join(sys.version.split(" ")[0].split(".")[:-1])
result = requests.get(
f'https://gitlab.caltech.edu/cs1-24fa/lecture-code/-/raw/master/e1/checker/checker.cpython-{version}.pyc')
with open('checker.pyc', 'wb') as f:
f.write(result.content)
def load(x):
spec = importlib.util.spec_from_file_location(
x, f"checker.pyc")
mod = importlib.util.module_from_spec(spec)
spec.loader.exec_module(mod)
return mod
checker = load('checker')
check = checker.check
-
Adam Blank authoredaaa6c245