(cls, name, index_dir, archive_file)
| 158 | |
| 159 | @classmethod |
| 160 | def from_file(cls, name, index_dir, archive_file): |
| 161 | with open(archive_file, "rb") as f: |
| 162 | checksum = hashlib.sha256(f.read()).hexdigest() |
| 163 | return cls( |
| 164 | name=name, |
| 165 | index_dir=index_dir, |
| 166 | archive_file=archive_file, |
| 167 | checksum=checksum, |
| 168 | ) |
| 169 | |
| 170 | def simple_index_entry(self, base_url): |
| 171 | return ( |
no test coverage detected