mirror of
https://github.com/ihaveamac/custom-install.git
synced 2025-12-06 06:41:45 +00:00
update to pyctr 0.4.1, catch exceptions when creating CIAReader
This commit is contained in:
@@ -20,7 +20,7 @@ if TYPE_CHECKING:
|
||||
|
||||
from events import Events
|
||||
|
||||
from pyctr.crypto import CryptoEngine, Keyslot
|
||||
from pyctr.crypto import CryptoEngine, Keyslot, load_seeddb
|
||||
from pyctr.type.cia import CIAReader, CIASection
|
||||
from pyctr.type.ncch import NCCHSection
|
||||
from pyctr.util import roundup
|
||||
@@ -173,12 +173,19 @@ class CustomInstall:
|
||||
title_info_entries = {}
|
||||
cifinish_data = load_cifinish(cifinish_path)
|
||||
|
||||
load_seeddb(self.seeddb)
|
||||
|
||||
# Now loop through all provided cia files
|
||||
|
||||
for c in self.cias:
|
||||
self.log('Reading ' + c)
|
||||
|
||||
cia = CIAReader(c, seeddb=self.seeddb)
|
||||
try:
|
||||
cia = CIAReader(c)
|
||||
except Exception as e:
|
||||
self.log(f'Failed to load file: {type(e).__name__}: {e}')
|
||||
continue
|
||||
|
||||
self.cia = cia
|
||||
|
||||
tid_parts = (cia.tmd.title_id[0:8], cia.tmd.title_id[8:16])
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
pycryptodomex<=3.9.4
|
||||
events==0.3
|
||||
pyctr==0.1.0
|
||||
pyctr==0.4.1
|
||||
|
||||
Reference in New Issue
Block a user