"""Check the extracted C01 package with Python's standard library."""
from pathlib import Path
import hashlib,json
root=Path(__file__).resolve().parent
manifest=json.loads((root/'PACKAGE_MANIFEST.json').read_text())
for item in manifest['files']:
    p=root/item['path'];b=p.read_bytes()
    assert len(b)==item['bytes'] and hashlib.sha256(b).hexdigest()==item['sha256'],item['path']
print('PASS:',len(manifest['files']),'C01 files match the issued manifest. Model approval remains separate.')
