ipsw-parser 1.9.0__tar.gz → 1.9.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/PKG-INFO +1 -1
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser/_version.py +3 -3
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser/ipsw.py +8 -3
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser.egg-info/PKG-INFO +1 -1
- ipsw_parser-1.9.1/ipsw_parser.egg-info/scm_version.json +8 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/tests/test_archive_backends.py +10 -0
- ipsw_parser-1.9.0/ipsw_parser.egg-info/scm_version.json +0 -8
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/.gitattributes +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/.github/ISSUE_TEMPLATE/feature_request.md +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/.github/workflows/codeql.yml +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/.github/workflows/python-app.yml +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/.github/workflows/python-publish.yml +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/.gitignore +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/.pre-commit-config.yaml +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/CODE_OF_CONDUCT.md +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/LICENSE +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/README.md +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser/__init__.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser/__main__.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser/archive.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser/build_identity.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser/build_manifest.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser/component.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser/dsc.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser/exceptions.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser/firmware.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser/process.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser/py.typed +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser.egg-info/SOURCES.txt +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser.egg-info/dependency_links.txt +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser.egg-info/entry_points.txt +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser.egg-info/requires.txt +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser.egg-info/scm_file_list.json +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/ipsw_parser.egg-info/top_level.txt +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/pyproject.toml +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/pytest.ini +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/requirements.txt +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/setup.cfg +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/tests/test_dsc.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/tests/test_firmware.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/tests/test_kernelcache.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/tests/test_process.py +0 -0
- {ipsw_parser-1.9.0 → ipsw_parser-1.9.1}/tests/test_sandbox_profiles.py +0 -0
|
@@ -18,7 +18,7 @@ version_tuple: tuple[int | str, ...]
|
|
|
18
18
|
commit_id: str | None
|
|
19
19
|
__commit_id__: str | None
|
|
20
20
|
|
|
21
|
-
__version__ = version = '1.9.
|
|
22
|
-
__version_tuple__ = version_tuple = (1, 9,
|
|
21
|
+
__version__ = version = '1.9.1'
|
|
22
|
+
__version_tuple__ = version_tuple = (1, 9, 1)
|
|
23
23
|
|
|
24
|
-
__commit_id__ = commit_id = '
|
|
24
|
+
__commit_id__ = commit_id = 'g2a4e9daf9'
|
|
@@ -13,6 +13,7 @@ from remotezip2 import RemoteZip # pyright: ignore[reportMissingTypeStubs]
|
|
|
13
13
|
from ipsw_parser.archive import Archive, ArchiveEntry, DirectoryArchive, ZipArchive
|
|
14
14
|
from ipsw_parser.build_manifest import BuildManifest
|
|
15
15
|
from ipsw_parser.dsc import create_device_support_layout
|
|
16
|
+
from ipsw_parser.exceptions import IpswException
|
|
16
17
|
from ipsw_parser.firmware import Firmware
|
|
17
18
|
|
|
18
19
|
logger = logging.getLogger(__name__)
|
|
@@ -71,11 +72,15 @@ class IPSW:
|
|
|
71
72
|
"""Create an IPSW wrapper around an archive backend."""
|
|
72
73
|
self.archive = archive
|
|
73
74
|
self._logger = logging.getLogger(__file__)
|
|
75
|
+
try:
|
|
76
|
+
manifest_name = next(
|
|
77
|
+
f for f in self.archive.namelist() if f.startswith("BuildManifest") and f.endswith(".plist")
|
|
78
|
+
)
|
|
79
|
+
except StopIteration:
|
|
80
|
+
raise IpswException("archive does not contain a BuildManifest*.plist file") from None
|
|
74
81
|
self.build_manifest = BuildManifest(
|
|
75
82
|
self,
|
|
76
|
-
self.archive.read(
|
|
77
|
-
next(f for f in self.archive.namelist() if f.startswith("BuildManifest") and f.endswith(".plist"))
|
|
78
|
-
),
|
|
83
|
+
self.archive.read(manifest_name),
|
|
79
84
|
)
|
|
80
85
|
|
|
81
86
|
@cached_property
|
|
@@ -2,7 +2,10 @@ import plistlib
|
|
|
2
2
|
from pathlib import Path
|
|
3
3
|
from zipfile import ZipFile, ZipInfo
|
|
4
4
|
|
|
5
|
+
import pytest
|
|
6
|
+
|
|
5
7
|
from ipsw_parser.archive import DirectoryArchive, ZipArchive
|
|
8
|
+
from ipsw_parser.exceptions import IpswException
|
|
6
9
|
from ipsw_parser.ipsw import IPSW
|
|
7
10
|
|
|
8
11
|
|
|
@@ -56,6 +59,13 @@ def test_zip_archive_supports_same_ipsw_behavior(tmp_path: Path) -> None:
|
|
|
56
59
|
assert ipsw.get_development_files() == ["Firmware/devel-file.bin"]
|
|
57
60
|
|
|
58
61
|
|
|
62
|
+
def test_archive_without_manifest_raises_clean_error(tmp_path: Path) -> None:
|
|
63
|
+
(tmp_path / "not-a-manifest.txt").write_bytes(b"nope")
|
|
64
|
+
|
|
65
|
+
with pytest.raises(IpswException, match="BuildManifest"):
|
|
66
|
+
IPSW(DirectoryArchive(tmp_path))
|
|
67
|
+
|
|
68
|
+
|
|
59
69
|
def test_directory_extractall_copies_requested_members(tmp_path: Path) -> None:
|
|
60
70
|
source = tmp_path / "source"
|
|
61
71
|
source.mkdir()
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|