Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ from the module's release listing below.

| Module | Formats | Release | ChangeLog |
|--------|---------|---------|-----------|
| Ren'Py | `.rpa` (RPA-2.0, RPA-3.0) | [renpy](https://github.com/refaim/unpackrat/releases?q=renpy) | [RU](src/modules/renpy/ChangeLog.ru.txt) [EN](src/modules/renpy/ChangeLog.en.txt) |
| Ren'Py | `.rpa` (RPA-1.0 with adjacent `.rpi`, RPA-2.0, RPA-3.0) | [renpy](https://github.com/refaim/unpackrat/releases?q=renpy) | [RU](src/modules/renpy/ChangeLog.ru.txt) [EN](src/modules/renpy/ChangeLog.en.txt) |
| RPG Maker | `.rgssad` (XP, RGSS1), `.rgss2a` (VX, RGSS2), `.rgss3a` (VX Ace, RGSS3) | [rpgmaker](https://github.com/refaim/unpackrat/releases?q=rpgmaker) | [RU](src/modules/rpgmaker/ChangeLog.ru.txt) [EN](src/modules/rpgmaker/ChangeLog.en.txt) |
| Zanzarah | `.pak` | [zanzarah 2.3.0](https://github.com/refaim/unpackrat/releases?q=zanzarah) | [RU](src/modules/zanzarah/ChangeLog.ru.txt) [EN](src/modules/zanzarah/ChangeLog.en.txt) |
| Godot | `.pck` | [godot 1.2.0](https://github.com/refaim/unpackrat/releases?q=godot) | [RU](src/modules/godot/ChangeLog.ru.txt) [EN](src/modules/godot/ChangeLog.en.txt) |
Expand Down
2 changes: 2 additions & 0 deletions build/projects/fuzz-renpy.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,14 @@
<ClCompile Include="$(RepositoryRoot)src\core\compression\zlib_codec.cpp" />
<ClCompile Include="$(RepositoryRoot)src\modules\renpy\renpy.cpp" />
<ClCompile Include="$(RepositoryRoot)src\modules\renpy\pickle.cpp" />
<ClCompile Include="$(RepositoryRoot)src\modules\renpy\rpa1_index.cpp" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="$(RepositoryRoot)src\core\io\bounded_stream.h" />
<ClInclude Include="$(RepositoryRoot)src\modules\extractor.h" />
<ClInclude Include="$(RepositoryRoot)src\core\compression\zlib_codec.h" />
<ClInclude Include="$(RepositoryRoot)src\modules\renpy\pickle.h" />
<ClInclude Include="$(RepositoryRoot)src\modules\renpy\rpa1_index.h" />
</ItemGroup>

<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
Expand Down
2 changes: 2 additions & 0 deletions build/projects/renpy.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
<ClCompile Include="$(RepositoryRoot)src\core\compression\zlib_codec.cpp" />
<ClCompile Include="$(RepositoryRoot)src\modules\renpy\renpy.cpp" />
<ClCompile Include="$(RepositoryRoot)src\modules\renpy\pickle.cpp" />
<ClCompile Include="$(RepositoryRoot)src\modules\renpy\rpa1_index.cpp" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="$(RepositoryRoot)src\core\io\bounded_stream.h" />
Expand All @@ -42,6 +43,7 @@
<ClInclude Include="$(RepositoryRoot)src\core\compression\zlib_codec.h" />
<ClInclude Include="$(RepositoryRoot)src\modules\extractor.h" />
<ClInclude Include="$(RepositoryRoot)src\modules\renpy\pickle.h" />
<ClInclude Include="$(RepositoryRoot)src\modules\renpy\rpa1_index.h" />
</ItemGroup>

<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
Expand Down
2 changes: 2 additions & 0 deletions build/projects/tests.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,8 @@
<ObjectFileName>$(IntDir)pickle_unit.obj</ObjectFileName>
</ClCompile>
<ClCompile Include="$(RepositoryRoot)src\tests\unit\zlib.cpp" />
<ClCompile Include="$(RepositoryRoot)src\tests\unit\renpy_rpa1_index.cpp" />
<ClCompile Include="$(RepositoryRoot)src\modules\renpy\rpa1_index.cpp" />
<ClCompile Include="$(RepositoryRoot)src\tests\unit\bounded_stream.cpp">
<ObjectFileName>$(IntDir)bounded_stream_unit.obj</ObjectFileName>
</ClCompile>
Expand Down
67 changes: 65 additions & 2 deletions build/tests/test_supported_architecture_docs.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,12 @@
DOCUMENTS = (README, AGENTS, BUILD_SYSTEM, METHODOLOGY)

MODULES = ("renpy", "rpgmaker", "zanzarah", "godot")
CONSOLIDATED_RELEASES = {
"renpy": "3.2.0",
"rpgmaker": "1.3.0",
"zanzarah": "2.3.0",
"godot": "1.2.0",
}
LANGUAGES = ("en", "ru")


Expand Down Expand Up @@ -177,6 +183,52 @@ def test_methodology_describes_the_real_binary_gate_without_removed_checks(self)
self.assertIn("forbidden imports", docs)
self.assertIn("BinSkim", docs)

def test_future_changelog_release_keeps_the_historical_windows_announcement(self) -> None:
for language, header, announcement in (
("en", "Version", "+ Added support for Windows XP–11."),
("ru", "Версия", "+ Добавлена поддержка Windows XP–11."),
):
with self.subTest(language=language):
changelog = (
f"{header} 99.0.0\n-------------\n + Added a future feature.\n\n"
f"{header} 3.2.0\n-------------\n {announcement}\n\n"
f"{header} 1.0.0\n-------------\n + Original release.\n"
)
case = SupportedArchitectureDocumentTests(
"test_changelogs_drop_the_arm_build_claim_and_keep_the_version_history"
)
with (
mock.patch(__name__ + ".MODULES", ("renpy",)),
mock.patch(__name__ + ".LANGUAGES", (language,)),
mock.patch(__name__ + ".read", return_value=changelog),
mock.patch.object(Path, "read_text", return_value="99.0.0"),
):
case.test_changelogs_drop_the_arm_build_claim_and_keep_the_version_history()

def test_latest_or_other_release_cannot_replace_the_consolidated_windows_announcement(self) -> None:
for language, header, announcement in (
("en", "Version", "+ Added support for Windows XP–11."),
("ru", "Версия", "+ Добавлена поддержка Windows XP–11."),
):
with self.subTest(language=language):
changelog = (
f"{header} 99.0.0\n-------------\n {announcement}\n\n"
f"{header} 3.2.0\n-------------\n + A different historical feature.\n\n"
f"{header} 3.1.0\n-------------\n {announcement}\n\n"
f"{header} 1.0.0\n-------------\n + Original release.\n"
)
case = SupportedArchitectureDocumentTests(
"test_changelogs_drop_the_arm_build_claim_and_keep_the_version_history"
)
with (
mock.patch(__name__ + ".MODULES", ("renpy",)),
mock.patch(__name__ + ".LANGUAGES", (language,)),
mock.patch(__name__ + ".read", return_value=changelog),
mock.patch.object(Path, "read_text", return_value="99.0.0"),
self.assertRaisesRegex(AssertionError, "XP"),
):
case.test_changelogs_drop_the_arm_build_claim_and_keep_the_version_history()

def test_changelogs_drop_the_arm_build_claim_and_keep_the_version_history(self) -> None:
headers = {"en": "Version", "ru": "\u0412\u0435\u0440\u0441\u0438\u044f"}
for module in MODULES:
Expand All @@ -203,8 +255,19 @@ def test_changelogs_drop_the_arm_build_claim_and_keep_the_version_history(self)
line for line in body[:end] if line.lstrip().startswith(("*", "+"))
]
self.assertGreaterEqual(len(entries), 1)
# Every consolidated current release announces Windows XP..11 support;
# a historical announcement alone does not satisfy the release contract.
# The Windows support announcement belongs to its original consolidated
# release. New releases keep that exact historical section without
# repeating the announcement as if Windows support were newly added.
consolidated = f"{headers[language]} {CONSOLIDATED_RELEASES[module]}"
self.assertIn(consolidated, lines)
body = lines[lines.index(consolidated) + 2:]
end = next(
(index for index, line in enumerate(body) if line.startswith(headings)),
len(body),
)
entries = [
line for line in body[:end] if line.lstrip().startswith(("*", "+"))
]
announcement = {
"en": "+ Added support for Windows XP–11.",
"ru": "+ Добавлена поддержка Windows XP–11.",
Expand Down
6 changes: 6 additions & 0 deletions src/modules/renpy/ChangeLog.en.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
Version 3.3.0
-------------
+ Added support for RPA 1.0 archives with adjacent .rpi indexes, including files stored in multiple fragments.
* Validate legacy index paths, fragment bounds and metadata limits before opening an archive.
* Limit object and string copying while parsing Pickle indexes to reject memo amplification safely.

Version 3.2.0
-------------
+ Added support for Windows XP–11.
Expand Down
6 changes: 6 additions & 0 deletions src/modules/renpy/ChangeLog.ru.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
Версия 3.3.0
-------------
+ Добавлена поддержка архивов RPA 1.0 с соседним индексом .rpi, включая файлы из нескольких фрагментов.
* До открытия архива проверяются пути, границы фрагментов и ограничения размера старого индекса.
* Ограничено копирование объектов и строк в индексах Pickle для защиты от раздувания через memo.

Версия 3.2.0
-------------
+ Добавлена поддержка Windows XP–11.
Expand Down
2 changes: 1 addition & 1 deletion src/modules/renpy/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.2.0
3.3.0
Loading
Loading