mirror of
https://github.com/rommapp/romm.git
synced 2026-11-30 18:42:34 +01:00
fix(switch): explain why encrypted dumps get no title id (#5428)
* fix(switch): explain why encrypted dumps get no title id RomM doesn't read prod.keys, so encrypted retail NSP/XCI dumps resolve no title id, and nothing said so. A scan now logs one info line counting the encrypted Switch files it skipped, a Switch game without a title id says why on its metadata tab, and key files in the Firmware tab are marked as not used by RomM. Fixes #5330 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * fix(switch): keep each scan's encrypted file count separate Addresses Greptile's review on #5428: scans overlapping in one process (DEV_MODE) shared the module-level set, so a second scan's begin_scan cleared the first's count. The set now lives in a context var that each scan's rom tasks inherit. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
committed by
GitHub
parent
fe11afefe3
commit
f6002a76a3
@@ -1,8 +1,10 @@
|
||||
import asyncio
|
||||
from contextvars import ContextVar
|
||||
from dataclasses import dataclass
|
||||
from pathlib import Path
|
||||
from typing import Final
|
||||
|
||||
from logger.formatter import highlight as hl
|
||||
from logger.logger import log
|
||||
from utils.filesystem import COMPRESSED_FILE_SUFFIXES
|
||||
from utils.m3u import first_playlist_entry
|
||||
@@ -34,6 +36,28 @@ SIGIL_PLATFORM_SLUGS: Final[dict[str, str]] = {
|
||||
# and it is the only family whose files may carry their title id in the filename.
|
||||
SWITCH_PLATFORM_SLUGS: Final = frozenset({UPS.SWITCH, UPS.SWITCH_2})
|
||||
|
||||
# Files the current scan skipped because RomM holds no keys for their headers.
|
||||
# A context var, so scans overlapping in one process (DEV_MODE) keep their own.
|
||||
_needs_key_paths: ContextVar[set[str] | None] = ContextVar(
|
||||
"sigil_needs_key_paths", default=None
|
||||
)
|
||||
|
||||
|
||||
def begin_scan() -> None:
|
||||
_needs_key_paths.set(set())
|
||||
|
||||
|
||||
def log_scan_summary() -> None:
|
||||
"""Say how many encrypted Switch files this scan left without a title id."""
|
||||
paths = _needs_key_paths.get()
|
||||
if not paths:
|
||||
return
|
||||
log.info(
|
||||
f"{hl(str(len(paths)))} encrypted Switch files got no title id: "
|
||||
"RomM doesn't decrypt Switch files. Decrypted dumps, or a client "
|
||||
"holding your keys, can identify them."
|
||||
)
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class SigilExtractionResult:
|
||||
@@ -84,12 +108,16 @@ class SigilService:
|
||||
result = await asyncio.to_thread(
|
||||
sigil.extract, file_path, platform=sigil_slug, filename_fallback=False
|
||||
)
|
||||
# Expected for arbitrary library files: no title id, a format sigil
|
||||
# can't parse, or a Switch header RomM holds no keys for.
|
||||
# A Switch header RomM holds no keys for, reported in the scan summary.
|
||||
except sigil.SigilNeedsKeyError as exc:
|
||||
if (paths := _needs_key_paths.get()) is not None:
|
||||
paths.add(file_path)
|
||||
log.debug(f"Sigil found no title id for {file_path}: {exc}")
|
||||
return None
|
||||
# Expected for arbitrary library files: no title id or a format sigil can't parse.
|
||||
except (
|
||||
sigil.SigilNotFoundError,
|
||||
sigil.SigilUnsupportedFormatError,
|
||||
sigil.SigilNeedsKeyError,
|
||||
) as exc:
|
||||
log.debug(f"Sigil found no title id for {file_path}: {exc}")
|
||||
return None
|
||||
|
||||
@@ -18,6 +18,8 @@ from rq.timeouts import JobTimeoutException
|
||||
from sqlalchemy.exc import IntegrityError
|
||||
|
||||
from adapters.services.sigil import SWITCH_PLATFORM_SLUGS
|
||||
from adapters.services.sigil import begin_scan as begin_sigil_scan
|
||||
from adapters.services.sigil import log_scan_summary as log_sigil_scan_summary
|
||||
from config import DEV_MODE, SCAN_TIMEOUT, SCAN_WORKERS, TASK_RESULT_TTL
|
||||
from config.config_manager import config_manager as cm
|
||||
from endpoints.responses.platform import PlatformSchema
|
||||
@@ -1232,6 +1234,7 @@ async def scan_platforms(
|
||||
# overlap, and resetting would drop the other scan's limits and skips.
|
||||
if MetadataSource.SS in metadata_sources:
|
||||
await begin_ss_scan()
|
||||
begin_sigil_scan()
|
||||
|
||||
fs_platforms: list[str] = []
|
||||
if not roms_ids:
|
||||
@@ -1396,6 +1399,7 @@ async def scan_platforms(
|
||||
|
||||
if MetadataSource.SS in metadata_sources:
|
||||
log_ss_scan_summary()
|
||||
log_sigil_scan_summary()
|
||||
|
||||
log.info(f"{emoji.EMOJI_CHECK_MARK} Scan completed")
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import asyncio
|
||||
import types
|
||||
from pathlib import Path
|
||||
from unittest.mock import Mock
|
||||
@@ -6,6 +7,7 @@ import pytest
|
||||
|
||||
import adapters.services.sigil as sigil_adapter
|
||||
from adapters.services.sigil import SigilExtractionResult, SigilService
|
||||
from logger.formatter import highlight as hl
|
||||
from utils.platform_slugs import UniversalPlatformSlug as UPS
|
||||
|
||||
|
||||
@@ -243,3 +245,64 @@ class TestSigilService:
|
||||
platform="switch",
|
||||
filename_fallback=False,
|
||||
)
|
||||
|
||||
|
||||
class TestScanSummary:
|
||||
@pytest.mark.asyncio
|
||||
async def test_counts_encrypted_files_once_per_scan(self, monkeypatch, mocker):
|
||||
extract = Mock(side_effect=FakeNeedsKeyError(-6))
|
||||
monkeypatch.setattr(sigil_adapter, "sigil", make_fake_sigil(extract))
|
||||
log = mocker.patch.object(sigil_adapter, "log")
|
||||
service = SigilService()
|
||||
|
||||
sigil_adapter.begin_scan()
|
||||
await service.extract_title_id(UPS.SWITCH, "/roms/switch/a.nsp")
|
||||
await service.extract_title_id(UPS.SWITCH, "/roms/switch/a.nsp")
|
||||
await service.extract_title_id(UPS.SWITCH, "/roms/switch/b.xci")
|
||||
sigil_adapter.log_scan_summary()
|
||||
|
||||
log.info.assert_called_once()
|
||||
assert "2" in log.info.call_args.args[0]
|
||||
|
||||
@pytest.mark.asyncio
|
||||
async def test_new_scan_drops_the_last_count(self, monkeypatch, mocker):
|
||||
extract = Mock(side_effect=FakeNeedsKeyError(-6))
|
||||
monkeypatch.setattr(sigil_adapter, "sigil", make_fake_sigil(extract))
|
||||
log = mocker.patch.object(sigil_adapter, "log")
|
||||
|
||||
sigil_adapter.begin_scan()
|
||||
await SigilService().extract_title_id(UPS.SWITCH, "/roms/switch/a.nsp")
|
||||
sigil_adapter.begin_scan()
|
||||
sigil_adapter.log_scan_summary()
|
||||
|
||||
log.info.assert_not_called()
|
||||
|
||||
@pytest.mark.asyncio
|
||||
async def test_overlapping_scans_keep_their_own_count(self, monkeypatch, mocker):
|
||||
extract = Mock(side_effect=FakeNeedsKeyError(-6))
|
||||
monkeypatch.setattr(sigil_adapter, "sigil", make_fake_sigil(extract))
|
||||
log = mocker.patch.object(sigil_adapter, "log")
|
||||
first_scanned = asyncio.Event()
|
||||
second_began = asyncio.Event()
|
||||
|
||||
async def first_scan() -> None:
|
||||
sigil_adapter.begin_scan()
|
||||
await SigilService().extract_title_id(UPS.SWITCH, "/roms/switch/a.nsp")
|
||||
first_scanned.set()
|
||||
await second_began.wait()
|
||||
sigil_adapter.log_scan_summary()
|
||||
|
||||
async def second_scan() -> None:
|
||||
await first_scanned.wait()
|
||||
sigil_adapter.begin_scan()
|
||||
second_began.set()
|
||||
for name in ("b.nsp", "c.nsp", "d.xci"):
|
||||
await SigilService().extract_title_id(
|
||||
UPS.SWITCH, f"/roms/switch/{name}"
|
||||
)
|
||||
sigil_adapter.log_scan_summary()
|
||||
|
||||
await asyncio.gather(first_scan(), second_scan())
|
||||
|
||||
counts = sorted(call.args[0].split(" ")[0] for call in log.info.call_args_list)
|
||||
assert counts == [hl("1"), hl("3")]
|
||||
|
||||
@@ -106,6 +106,21 @@ describe("FirmwareTab", () => {
|
||||
});
|
||||
});
|
||||
|
||||
describe("FirmwareTab key files", () => {
|
||||
it("marks Switch key files as not used by RomM", () => {
|
||||
const wrapper = mountTab([
|
||||
firmware({ id: 1, file_name: "prod.keys" }),
|
||||
firmware({ id: 2, file_name: "title.keys" }),
|
||||
firmware({ id: 3, file_name: "BOOT0" }),
|
||||
]);
|
||||
|
||||
const keyChips = wrapper
|
||||
.findAllComponents({ name: "RChip" })
|
||||
.filter((c) => c.props("prependIcon") === "mdi-key-outline");
|
||||
expect(keyChips).toHaveLength(2);
|
||||
});
|
||||
});
|
||||
|
||||
describe("FirmwareTab selection", () => {
|
||||
const rows = [
|
||||
firmware({ id: 1 }),
|
||||
|
||||
@@ -50,6 +50,11 @@ const platformsStore = storePlatforms();
|
||||
const galleryRoms = storeGalleryRoms();
|
||||
const canWrite = useCan("platform.edit");
|
||||
|
||||
// Switch key files are stored for clients and emulators; RomM never reads them.
|
||||
function isKeyFile(f: FirmwareSchema): boolean {
|
||||
return f.file_name.toLowerCase().endsWith(".keys");
|
||||
}
|
||||
|
||||
const firmwareList = computed<FirmwareSchema[]>(
|
||||
() => props.platform.firmware ?? [],
|
||||
);
|
||||
@@ -392,6 +397,15 @@ async function performDelete(
|
||||
>
|
||||
{{ t("platform.firmware-verified", "Verified") }}
|
||||
</RChip>
|
||||
<RChip
|
||||
v-if="isKeyFile(f)"
|
||||
size="x-small"
|
||||
variant="translucent"
|
||||
prepend-icon="mdi-key-outline"
|
||||
:title="t('platform.firmware-keys-unused-tooltip')"
|
||||
>
|
||||
{{ t("platform.firmware-keys-unused") }}
|
||||
</RChip>
|
||||
</div>
|
||||
</div>
|
||||
<div class="r-fw__row-actions">
|
||||
|
||||
@@ -78,3 +78,30 @@ describe("MetadataTab verification chips", () => {
|
||||
expect(raChipTone(linkedOnly)).toBe("neutral");
|
||||
});
|
||||
});
|
||||
|
||||
describe("MetadataTab Switch title id", () => {
|
||||
function text(r: DetailedRom) {
|
||||
return shallowMount(MetadataTab, { props: { rom: r } }).text();
|
||||
}
|
||||
|
||||
it("explains a missing title id on a Switch game", () => {
|
||||
expect(text(rom({ platform_slug: "switch", title_id: null }))).toContain(
|
||||
"rom.title-id-missing-switch",
|
||||
);
|
||||
});
|
||||
|
||||
it("shows no explanation once the title id is known", () => {
|
||||
const body = text(
|
||||
rom({ platform_slug: "switch", title_id: "0100ABCD12340000" }),
|
||||
);
|
||||
|
||||
expect(body).toContain("0100ABCD12340000");
|
||||
expect(body).not.toContain("rom.title-id-missing-switch");
|
||||
});
|
||||
|
||||
it("leaves other platforms without a title id row", () => {
|
||||
expect(text(rom({ platform_slug: "psx", title_id: null }))).not.toContain(
|
||||
"rom.title-id",
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
@@ -13,7 +13,7 @@ import ProviderGrid from "@/components/GameDetails/ProviderGrid.vue";
|
||||
import HashChip from "@/components/shared/HashChip.vue";
|
||||
import { RTag } from "@/lib";
|
||||
import type { DetailedRom } from "@/stores/roms";
|
||||
import { formatBytes } from "@/utils";
|
||||
import { formatBytes, isSwitchSystem } from "@/utils";
|
||||
import { VERIFICATION_DATABASES } from "@/utils/romVerification";
|
||||
|
||||
defineOptions({ inheritAttrs: false });
|
||||
@@ -22,7 +22,7 @@ const props = defineProps<{ rom: DetailedRom }>();
|
||||
|
||||
const { t } = useI18n();
|
||||
|
||||
type Row = { label: string; value: string };
|
||||
type Row = { label: string; value: string; hint?: string };
|
||||
|
||||
const fileRows = computed<Row[]>(() => {
|
||||
const r = props.rom;
|
||||
@@ -31,7 +31,16 @@ const fileRows = computed<Row[]>(() => {
|
||||
{ label: t("rom.filename"), value: r.fs_name },
|
||||
{ label: t("common.size"), value: size },
|
||||
];
|
||||
if (r.title_id) rows.push({ label: t("rom.title-id"), value: r.title_id });
|
||||
if (r.title_id) {
|
||||
rows.push({ label: t("rom.title-id"), value: r.title_id });
|
||||
} else if (isSwitchSystem(r.platform_slug)) {
|
||||
// Most retail Switch dumps are encrypted, and RomM never reads the keys.
|
||||
rows.push({
|
||||
label: t("rom.title-id"),
|
||||
value: "—",
|
||||
hint: t("rom.title-id-missing-switch"),
|
||||
});
|
||||
}
|
||||
if (r.save_target)
|
||||
rows.push({ label: t("rom.save-target"), value: r.save_target });
|
||||
return rows;
|
||||
@@ -103,6 +112,7 @@ const downloadUrls = computed(() => {
|
||||
<div v-for="row in fileRows" :key="row.label" class="metadata-tab__row">
|
||||
<div class="metadata-tab__label">{{ row.label }}</div>
|
||||
<div class="metadata-tab__value">{{ row.value }}</div>
|
||||
<div v-if="row.hint" class="metadata-tab__hint">{{ row.hint }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
@@ -197,6 +207,11 @@ const downloadUrls = computed(() => {
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
.metadata-tab__hint {
|
||||
font-size: 12px;
|
||||
color: var(--r-color-fg-muted);
|
||||
}
|
||||
|
||||
/* Hashes & Verification: inline row, wraps when narrow. */
|
||||
.metadata-tab__inline {
|
||||
display: flex;
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Фърмуер / BIOS",
|
||||
"firmware-deleted-successfully": "Фърмуерът е изтрит успешно! | {count} фърмуера бяха изтрити успешно!",
|
||||
"firmware-dropzone-description": "Влачи и пусни фърмуер файлове тук или кликни, за да избереш",
|
||||
"firmware-keys-unused": "Не се използва от RomM",
|
||||
"firmware-keys-unused-tooltip": "Съхранява се за вашите клиенти и емулатори. RomM никога не чете файлове с ключове, затова криптираните дъмпове за Switch нямат Title ID.",
|
||||
"firmware-remove-warning": "Ще премахнеш {count} фърмуер от файловата си система. Това действие е необратимо! | Ще премахнеш {count} фърмуера от файловата си система. Това действие е необратимо!",
|
||||
"firmware-select-to-remove": "Избери фърмуер файловете които искаш да премахнеш от файловата система, в противен случай ще бъдат изтрити само от базата данни на RomM.",
|
||||
"firmware-uploaded-successfully": "{count} файл качен успешно. | {count} файла качени успешно.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Бележки",
|
||||
"tab-overview": "Преглед",
|
||||
"title-id": "ID на заглавието",
|
||||
"title-id-missing-switch": "RomM не дешифрира файлове за Switch, затова криптираните дъмпове нямат Title ID. Дешифрирани дъмпове или клиент с вашите ключове могат да идентифицират тази игра.",
|
||||
"tracks-n": "{n} песен | {n} песни",
|
||||
"tracks-summary": "{count} песни · {duration}",
|
||||
"unmatch": "Премахни разпознаването",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Firmware / BIOS",
|
||||
"firmware-deleted-successfully": "{count} firmware odstraněno! | {count} firmware odstraněn! | {count} firmware odstraněny! | {count} firmware odstraněno!",
|
||||
"firmware-dropzone-description": "Přetáhněte sem soubory firmwaru nebo klikněte pro výběr",
|
||||
"firmware-keys-unused": "RomM nepoužívá",
|
||||
"firmware-keys-unused-tooltip": "Uloženo pro vaše klienty a emulátory. RomM soubory s klíči nikdy nečte, takže šifrované dumpy Switch nemají Title ID.",
|
||||
"firmware-remove-warning": "Odstraníte {count} firmwarů ze systému. Akce je nevratná! | Odstraníte {count} firmware ze systému. Akce je nevratná! | Odstraníte {count} firmware ze systému. Akce je nevratná! | Odstraníte {count} firmwarů ze systému. Akce je nevratná!",
|
||||
"firmware-select-to-remove": "Vyberte firmwary k odstranění ze systému, jinak budou smazány pouze z databáze.",
|
||||
"firmware-uploaded-successfully": "{count} souborů nahráno. | {count} soubor nahrán. | {count} soubory nahrány. | {count} souborů nahráno.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Poznámky",
|
||||
"tab-overview": "Přehled",
|
||||
"title-id": "ID titulu",
|
||||
"title-id-missing-switch": "RomM nedešifruje soubory Switch, takže šifrované dumpy nemají Title ID. Hru dokážou identifikovat dešifrované dumpy nebo klient s vašimi klíči.",
|
||||
"tracks-n": "{n} skladeb | {n} skladba | {n} skladby | {n} skladeb",
|
||||
"tracks-summary": "{count} skladeb · {duration}",
|
||||
"unmatch": "Odpojit ROM",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Firmware / BIOS",
|
||||
"firmware-deleted-successfully": "Firmware gelöscht! | {count} Firmwares gelöscht!",
|
||||
"firmware-dropzone-description": "Firmware-Dateien hierher ziehen oder klicken zum Durchsuchen",
|
||||
"firmware-keys-unused": "Nicht von RomM verwendet",
|
||||
"firmware-keys-unused-tooltip": "Für deine Clients und Emulatoren gespeichert. RomM liest Schlüsseldateien nie, daher erhalten verschlüsselte Switch-Dumps keine Title-ID.",
|
||||
"firmware-remove-warning": "{count} Firmware vom System entfernen. Nicht rückgängig machbar! | {count} Firmwares vom System entfernen. Nicht rückgängig machbar!",
|
||||
"firmware-select-to-remove": "Wählen Sie Firmwares zum Entfernen aus dem System, sonst nur aus der Datenbank.",
|
||||
"firmware-uploaded-successfully": "{count} Datei hochgeladen. | {count} Dateien hochgeladen.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Notizen",
|
||||
"tab-overview": "Übersicht",
|
||||
"title-id": "Titel-ID",
|
||||
"title-id-missing-switch": "RomM entschlüsselt keine Switch-Dateien, daher erhalten verschlüsselte Dumps keine Title-ID. Entschlüsselte Dumps oder ein Client mit deinen Schlüsseln können dieses Spiel identifizieren.",
|
||||
"tracks-n": "{n} Track | {n} Tracks",
|
||||
"tracks-summary": "{count} Tracks · {duration}",
|
||||
"unmatch": "Zuweisung aufheben",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Firmware / BIOS",
|
||||
"firmware-deleted-successfully": "Firmware deleted successfully! | {count} firmwares deleted successfully!",
|
||||
"firmware-dropzone-description": "Drag and drop firmware files here, or click to browse",
|
||||
"firmware-keys-unused": "Not used by RomM",
|
||||
"firmware-keys-unused-tooltip": "Stored for your clients and emulators. RomM never reads key files, so encrypted Switch dumps get no title ID.",
|
||||
"firmware-remove-warning": "You are going to remove {count} firmware from your filesystem. This action can't be reverted! | You are going to remove {count} firmwares from your filesystem. This action can't be reverted!",
|
||||
"firmware-select-to-remove": "Select the firmware files you want to remove from your filesystem, otherwise they will only be deleted from RomM database.",
|
||||
"firmware-uploaded-successfully": "{count} file uploaded successfully. | {count} files uploaded successfully.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Notes",
|
||||
"tab-overview": "Overview",
|
||||
"title-id": "Title ID",
|
||||
"title-id-missing-switch": "RomM doesn't decrypt Switch files, so encrypted dumps get no title ID. Decrypted dumps, or a client holding your keys, can identify this game.",
|
||||
"tracks-n": "{n} track | {n} tracks",
|
||||
"tracks-summary": "{count} tracks · {duration}",
|
||||
"unmatch": "Unmatch ROM",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Firmware / BIOS",
|
||||
"firmware-deleted-successfully": "Firmware deleted successfully! | {count} firmwares deleted successfully!",
|
||||
"firmware-dropzone-description": "Drag and drop firmware files here, or click to browse",
|
||||
"firmware-keys-unused": "Not used by RomM",
|
||||
"firmware-keys-unused-tooltip": "Stored for your clients and emulators. RomM never reads key files, so encrypted Switch dumps get no title ID.",
|
||||
"firmware-remove-warning": "You are going to remove {count} firmware from your filesystem. This action can't be reverted! | You are going to remove {count} firmwares from your filesystem. This action can't be reverted!",
|
||||
"firmware-select-to-remove": "Select the firmware files you want to remove from your filesystem, otherwise they will only be deleted from RomM database.",
|
||||
"firmware-uploaded-successfully": "{count} file uploaded successfully. | {count} files uploaded successfully.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Notes",
|
||||
"tab-overview": "Overview",
|
||||
"title-id": "Title ID",
|
||||
"title-id-missing-switch": "RomM doesn't decrypt Switch files, so encrypted dumps get no title ID. Decrypted dumps, or a client holding your keys, can identify this game.",
|
||||
"tracks-n": "{n} track | {n} tracks",
|
||||
"tracks-summary": "{count} tracks · {duration}",
|
||||
"unmatch": "Unmatch ROM",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Firmware / BIOS",
|
||||
"firmware-deleted-successfully": "¡Firmware eliminado! | ¡{count} firmwares eliminados!",
|
||||
"firmware-dropzone-description": "Arrastra y suelta archivos de firmware aquí, o haz clic para examinar",
|
||||
"firmware-keys-unused": "No lo usa RomM",
|
||||
"firmware-keys-unused-tooltip": "Se guarda para tus clientes y emuladores. RomM nunca lee los archivos de claves, así que los volcados cifrados de Switch no obtienen Title ID.",
|
||||
"firmware-remove-warning": "Va a eliminar {count} firmware del sistema. ¡Acción irreversible! | Va a eliminar {count} firmwares del sistema. ¡Acción irreversible!",
|
||||
"firmware-select-to-remove": "Seleccione los firmwares a eliminar del sistema, de lo contrario solo se borrarán de la base de datos.",
|
||||
"firmware-uploaded-successfully": "{count} archivo subido. | {count} archivos subidos.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Notas",
|
||||
"tab-overview": "Resumen",
|
||||
"title-id": "ID del título",
|
||||
"title-id-missing-switch": "RomM no descifra archivos de Switch, así que los volcados cifrados no obtienen Title ID. Los volcados descifrados, o un cliente con tus claves, pueden identificar este juego.",
|
||||
"tracks-n": "{n} pista | {n} pistas",
|
||||
"tracks-summary": "{count} pistas · {duration}",
|
||||
"unmatch": "Desvincular ROM",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Firmware / BIOS",
|
||||
"firmware-deleted-successfully": "Firmware supprimé ! | {count} firmwares supprimés !",
|
||||
"firmware-dropzone-description": "Glissez-déposez les fichiers de firmware ici, ou cliquez pour parcourir",
|
||||
"firmware-keys-unused": "Non utilisé par RomM",
|
||||
"firmware-keys-unused-tooltip": "Conservé pour vos clients et émulateurs. RomM ne lit jamais les fichiers de clés, donc les dumps Switch chiffrés n'obtiennent pas de Title ID.",
|
||||
"firmware-remove-warning": "Vous allez supprimer {count} firmware du système. Action irréversible ! | Vous allez supprimer {count} firmwares du système. Action irréversible !",
|
||||
"firmware-select-to-remove": "Sélectionnez les firmwares à supprimer du système, sinon seule la base RomM sera affectée.",
|
||||
"firmware-uploaded-successfully": "{count} fichier envoyé. | {count} fichiers envoyés.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Notes",
|
||||
"tab-overview": "Aperçu",
|
||||
"title-id": "ID du titre",
|
||||
"title-id-missing-switch": "RomM ne déchiffre pas les fichiers Switch, donc les dumps chiffrés n'obtiennent pas de Title ID. Un dump déchiffré, ou un client possédant vos clés, peut identifier ce jeu.",
|
||||
"tracks-n": "{n} piste | {n} pistes",
|
||||
"tracks-summary": "{count} pistes · {duration}",
|
||||
"unmatch": "Dissocier le ROM",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Firmware / BIOS",
|
||||
"firmware-deleted-successfully": "Firmware sikeresen törölve! | {count} firmware sikeresen törölve!",
|
||||
"firmware-dropzone-description": "Húzd ide a firmware fájlokat, vagy kattints a tallózáshoz",
|
||||
"firmware-keys-unused": "A RomM nem használja",
|
||||
"firmware-keys-unused-tooltip": "A klienseid és emulátoraid számára tárolva. A RomM soha nem olvassa a kulcsfájlokat, így a titkosított Switch dumpok nem kapnak Title ID-t.",
|
||||
"firmware-remove-warning": "El fogsz távolítani {count} firmware-t a fájlrendszerből. Ez a művelet nem vonható vissza! | El fogsz távolítani {count} firmware-eket a fájlrendszerből. Ez a művelet nem vonható vissza!",
|
||||
"firmware-select-to-remove": "Válasszd ki a fájlrendszerből eltávolítani kívánt firmware fájlokat, ellenkező esetben azok csak a RomM adatbázisból lesznek törölve.",
|
||||
"firmware-uploaded-successfully": "{count} fájl sikeresen feltöltve. | {count} fájlok sikeresen feltöltve.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Jegyzetek",
|
||||
"tab-overview": "Áttekintés",
|
||||
"title-id": "Cím ID",
|
||||
"title-id-missing-switch": "A RomM nem fejti vissza a Switch fájlokat, így a titkosított dumpok nem kapnak Title ID-t. Visszafejtett dumpok vagy a kulcsaidat birtokló kliens azonosíthatja ezt a játékot.",
|
||||
"tracks-n": "{n} szám | {n} szám",
|
||||
"tracks-summary": "{count} szám · {duration}",
|
||||
"unmatch": "Nem egyező ROM",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Firmware / BIOS",
|
||||
"firmware-deleted-successfully": "Firmware eliminato! | {count} firmware eliminati!",
|
||||
"firmware-dropzone-description": "Trascina e rilascia i file firmware qui, oppure clicca per sfogliare",
|
||||
"firmware-keys-unused": "Non usato da RomM",
|
||||
"firmware-keys-unused-tooltip": "Conservato per i tuoi client ed emulatori. RomM non legge mai i file di chiavi, quindi i dump Switch cifrati non ottengono un Title ID.",
|
||||
"firmware-remove-warning": "Rimuoverai {count} firmware dal sistema. Azione irreversibile! | Rimuoverai {count} firmware dal sistema. Azione irreversibile!",
|
||||
"firmware-select-to-remove": "Seleziona i firmware da rimuovere dal sistema, altrimenti verranno eliminati solo dal database.",
|
||||
"firmware-uploaded-successfully": "{count} file caricato. | {count} file caricati.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Note",
|
||||
"tab-overview": "Panoramica",
|
||||
"title-id": "ID titolo",
|
||||
"title-id-missing-switch": "RomM non decifra i file Switch, quindi i dump cifrati non ottengono un Title ID. Dump decifrati, o un client con le tue chiavi, possono identificare questo gioco.",
|
||||
"tracks-n": "{n} traccia | {n} tracce",
|
||||
"tracks-summary": "{count} tracce · {duration}",
|
||||
"unmatch": "Rimuovi associazione rom",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "ファームウェア / BIOS",
|
||||
"firmware-deleted-successfully": "ファームウェアを削除しました! | {count}個のファームウェアを削除しました!",
|
||||
"firmware-dropzone-description": "ファームウェアファイルをここにドラッグ&ドロップするか、クリックして参照してください",
|
||||
"firmware-keys-unused": "RomM では未使用",
|
||||
"firmware-keys-unused-tooltip": "クライアントやエミュレーター用に保存されています。RomM はキーファイルを読み込まないため、暗号化された Switch のダンプには Title ID が付きません。",
|
||||
"firmware-remove-warning": "システムから{count}個のファームウェアを削除します。元に戻せません!",
|
||||
"firmware-select-to-remove": "システムから削除するファームウェアを選択してください。選択しない場合はデータベースからのみ削除されます。",
|
||||
"firmware-uploaded-successfully": "{count}個のファイルをアップロードしました。",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "ノート",
|
||||
"tab-overview": "概要",
|
||||
"title-id": "タイトルID",
|
||||
"title-id-missing-switch": "RomM は Switch のファイルを復号しないため、暗号化されたダンプには Title ID が付きません。復号済みのダンプ、またはキーを持つクライアントならこのゲームを識別できます。",
|
||||
"tracks-n": "{n}件のトラック | {n}件のトラック",
|
||||
"tracks-summary": "{count}件のトラック · {duration}",
|
||||
"unmatch": "検索結果無し",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "펌웨어 / BIOS",
|
||||
"firmware-deleted-successfully": "펌웨어 삭제 완료! | {count}개 펌웨어 삭제 완료!",
|
||||
"firmware-dropzone-description": "펌웨어 파일을 여기에 끌어다 놓거나 클릭하여 탐색하세요",
|
||||
"firmware-keys-unused": "RomM에서 사용하지 않음",
|
||||
"firmware-keys-unused-tooltip": "클라이언트와 에뮬레이터용으로 저장됩니다. RomM은 키 파일을 읽지 않으므로 암호화된 Switch 덤프에는 Title ID가 없습니다.",
|
||||
"firmware-remove-warning": "시스템에서 {count}개 펌웨어를 제거합니다. 되돌릴 수 없습니다!",
|
||||
"firmware-select-to-remove": "시스템에서 제거할 펌웨어를 선택하세요. 선택하지 않으면 데이터베이스에서만 삭제됩니다.",
|
||||
"firmware-uploaded-successfully": "{count}개 파일 업로드 완료.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "노트",
|
||||
"tab-overview": "개요",
|
||||
"title-id": "타이틀 ID",
|
||||
"title-id-missing-switch": "RomM은 Switch 파일을 복호화하지 않으므로 암호화된 덤프에는 Title ID가 없습니다. 복호화된 덤프나 키를 가진 클라이언트로 이 게임을 식별할 수 있습니다.",
|
||||
"tracks-n": "{n}개 트랙 | {n}개 트랙",
|
||||
"tracks-summary": "{count}개 트랙 · {duration}",
|
||||
"unmatch": "DB 대응 해제",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Firmware / BIOS",
|
||||
"firmware-deleted-successfully": "Firmware usunięty! | {count} firmware'ów usuniętych!",
|
||||
"firmware-dropzone-description": "Przeciągnij i upuść pliki firmware tutaj lub kliknij, aby przeglądać",
|
||||
"firmware-keys-unused": "Nieużywane przez RomM",
|
||||
"firmware-keys-unused-tooltip": "Przechowywane dla Twoich klientów i emulatorów. RomM nigdy nie odczytuje plików kluczy, więc zaszyfrowane zrzuty Switch nie otrzymują Title ID.",
|
||||
"firmware-remove-warning": "Usuniesz {count} firmware z systemu. Nie można cofnąć! | Usuniesz {count} firmware'ów z systemu. Nie można cofnąć!",
|
||||
"firmware-select-to-remove": "Wybierz firmware do usunięcia z systemu, w przeciwnym razie zostaną usunięte tylko z bazy danych.",
|
||||
"firmware-uploaded-successfully": "{count} plik przesłany. | {count} plików przesłanych.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Notatki",
|
||||
"tab-overview": "Przegląd",
|
||||
"title-id": "ID tytułu",
|
||||
"title-id-missing-switch": "RomM nie odszyfrowuje plików Switch, więc zaszyfrowane zrzuty nie otrzymują Title ID. Tę grę mogą rozpoznać odszyfrowane zrzuty lub klient z Twoimi kluczami.",
|
||||
"tracks-n": "{n} utwór | {n} utwory | {n} utworów",
|
||||
"tracks-summary": "{count} utworów · {duration}",
|
||||
"unmatch": "Odłącz ROM",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Firmware / BIOS",
|
||||
"firmware-deleted-successfully": "Firmware excluído! | {count} firmwares excluídos!",
|
||||
"firmware-dropzone-description": "Arraste e solte arquivos de firmware aqui, ou clique para navegar",
|
||||
"firmware-keys-unused": "Não usado pelo RomM",
|
||||
"firmware-keys-unused-tooltip": "Armazenado para seus clientes e emuladores. O RomM nunca lê arquivos de chaves, então dumps de Switch criptografados não recebem Title ID.",
|
||||
"firmware-remove-warning": "Você vai remover {count} firmware do sistema. Ação irreversível! | Você vai remover {count} firmwares do sistema. Ação irreversível!",
|
||||
"firmware-select-to-remove": "Selecione os firmwares a remover do sistema, caso contrário serão excluídos apenas do banco de dados.",
|
||||
"firmware-uploaded-successfully": "{count} arquivo enviado. | {count} arquivos enviados.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Notas",
|
||||
"tab-overview": "Visão geral",
|
||||
"title-id": "ID do título",
|
||||
"title-id-missing-switch": "O RomM não descriptografa arquivos de Switch, então dumps criptografados não recebem Title ID. Dumps descriptografados, ou um cliente com suas chaves, podem identificar este jogo.",
|
||||
"tracks-n": "{n} faixa | {n} faixas",
|
||||
"tracks-summary": "{count} faixas · {duration}",
|
||||
"unmatch": "Desvincular ROM",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Firmware / BIOS",
|
||||
"firmware-deleted-successfully": "Firmware eliminat! | {count} firmware-uri eliminate!",
|
||||
"firmware-dropzone-description": "Trage și plasează fișierele de firmware aici sau apasă pentru a naviga",
|
||||
"firmware-keys-unused": "Nefolosit de RomM",
|
||||
"firmware-keys-unused-tooltip": "Stocat pentru clienții și emulatoarele tale. RomM nu citește niciodată fișierele cu chei, așa că dump-urile Switch criptate nu primesc Title ID.",
|
||||
"firmware-remove-warning": "Veți elimina {count} firmware din sistem. Acțiune ireversibilă! | Veți elimina {count} firmware-uri din sistem. Acțiune ireversibilă!",
|
||||
"firmware-select-to-remove": "Selectați firmware-urile de șters din sistem, altfel vor fi șterse doar din baza de date.",
|
||||
"firmware-uploaded-successfully": "{count} fișier încărcat. | {count} fișiere încărcate.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Notițe",
|
||||
"tab-overview": "Prezentare",
|
||||
"title-id": "ID titlu",
|
||||
"title-id-missing-switch": "RomM nu decriptează fișierele Switch, așa că dump-urile criptate nu primesc Title ID. Dump-urile decriptate sau un client care are cheile tale pot identifica acest joc.",
|
||||
"tracks-n": "{n} piesă | {n} piese",
|
||||
"tracks-summary": "{count} piese · {duration}",
|
||||
"unmatch": "Dissociază ROM-ul",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Прошивка / BIOS",
|
||||
"firmware-deleted-successfully": "Прошивка удалена! | {count} прошивок удалено!",
|
||||
"firmware-dropzone-description": "Перетащите файлы прошивки сюда или нажмите для выбора",
|
||||
"firmware-keys-unused": "Не используется RomM",
|
||||
"firmware-keys-unused-tooltip": "Хранится для ваших клиентов и эмуляторов. RomM никогда не читает файлы ключей, поэтому зашифрованные дампы Switch не получают Title ID.",
|
||||
"firmware-remove-warning": "Вы удалите {count} прошивку из системы. Действие необратимо! | Вы удалите {count} прошивок из системы. Действие необратимо!",
|
||||
"firmware-select-to-remove": "Выберите прошивки для удаления из системы, иначе они будут удалены только из базы данных.",
|
||||
"firmware-uploaded-successfully": "{count} файл загружен. | {count} файлов загружено.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Заметки",
|
||||
"tab-overview": "Обзор",
|
||||
"title-id": "ID тайтла",
|
||||
"title-id-missing-switch": "RomM не расшифровывает файлы Switch, поэтому зашифрованные дампы не получают Title ID. Определить эту игру могут расшифрованные дампы или клиент с вашими ключами.",
|
||||
"tracks-n": "{n} трек | {n} треков",
|
||||
"tracks-summary": "{count} треков · {duration}",
|
||||
"unmatch": "Отменить совпадение",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Firmware / BIOS",
|
||||
"firmware-deleted-successfully": "Firmware har tagits bort. | {count} firmwareposter har tagits bort.",
|
||||
"firmware-dropzone-description": "Dra och släpp firmwarefiler här eller klicka för att bläddra",
|
||||
"firmware-keys-unused": "Används inte av RomM",
|
||||
"firmware-keys-unused-tooltip": "Lagras för dina klienter och emulatorer. RomM läser aldrig nyckelfiler, så krypterade Switch-dumpar får inget Title ID.",
|
||||
"firmware-remove-warning": "Du håller på att ta bort {count} firmwarefil från filsystemet. Åtgärden kan inte ångras. | Du håller på att ta bort {count} firmwarefiler från filsystemet. Åtgärden kan inte ångras.",
|
||||
"firmware-select-to-remove": "Markera firmwarefilerna som ska tas bort från filsystemet. Annars tas de bara bort från RomM-databasen.",
|
||||
"firmware-uploaded-successfully": "{count} fil laddades upp. | {count} filer laddades upp.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Anteckningar",
|
||||
"tab-overview": "Översikt",
|
||||
"title-id": "Titel-ID",
|
||||
"title-id-missing-switch": "RomM dekrypterar inte Switch-filer, så krypterade dumpar får inget Title ID. Dekrypterade dumpar, eller en klient med dina nycklar, kan identifiera spelet.",
|
||||
"tracks-n": "{n} spår | {n} spår",
|
||||
"tracks-summary": "{count} spår · {duration}",
|
||||
"unmatch": "Ta bort ROM-matchning",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "Firmware / BIOS",
|
||||
"firmware-deleted-successfully": "Firmware başarıyla silindi! | {count} firmware başarıyla silindi!",
|
||||
"firmware-dropzone-description": "Firmware dosyalarını buraya sürükleyip bırakın veya göz atmak için tıklayın",
|
||||
"firmware-keys-unused": "RomM tarafından kullanılmaz",
|
||||
"firmware-keys-unused-tooltip": "İstemcileriniz ve emülatörleriniz için saklanır. RomM anahtar dosyalarını asla okumaz; bu yüzden şifreli Switch dökümleri Title ID almaz.",
|
||||
"firmware-remove-warning": "Dosya sisteminizden {count} firmware kaldıracaksınız. Bu işlem geri alınamaz! | Dosya sisteminizden {count} firmware kaldıracaksınız. Bu işlem geri alınamaz!",
|
||||
"firmware-select-to-remove": "Dosya sisteminizden kaldırmak istediğiniz firmware dosyalarını seçin; aksi takdirde yalnızca RomM veritabanından silinirler.",
|
||||
"firmware-uploaded-successfully": "{count} dosya başarıyla yüklendi. | {count} dosya başarıyla yüklendi.",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "Notlar",
|
||||
"tab-overview": "Genel Bakış",
|
||||
"title-id": "Başlık ID",
|
||||
"title-id-missing-switch": "RomM, Switch dosyalarının şifresini çözmez; bu yüzden şifreli dökümler Title ID almaz. Şifresi çözülmüş dökümler veya anahtarlarınıza sahip bir istemci bu oyunu tanımlayabilir.",
|
||||
"tracks-n": "{n} parça | {n} parça",
|
||||
"tracks-summary": "{count} parça · {duration}",
|
||||
"unmatch": "ROM eşleşmesini kaldır",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "固件 / BIOS",
|
||||
"firmware-deleted-successfully": "固件已删除! | 已删除{count}个固件!",
|
||||
"firmware-dropzone-description": "将固件文件拖放到此处,或点击浏览",
|
||||
"firmware-keys-unused": "RomM 不使用",
|
||||
"firmware-keys-unused-tooltip": "为你的客户端和模拟器保存。RomM 从不读取密钥文件,因此加密的 Switch 转储没有 Title ID。",
|
||||
"firmware-remove-warning": "您将从系统中删除{count}个固件。此操作无法撤销!",
|
||||
"firmware-select-to-remove": "选择要从系统中删除的固件,否则只会从数据库中删除。",
|
||||
"firmware-uploaded-successfully": "已上传{count}个文件。",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "笔记",
|
||||
"tab-overview": "概览",
|
||||
"title-id": "标题ID",
|
||||
"title-id-missing-switch": "RomM 不会解密 Switch 文件,因此加密的转储没有 Title ID。已解密的转储,或持有你密钥的客户端,可以识别此游戏。",
|
||||
"tracks-n": "{n} 个曲目 | {n} 个曲目",
|
||||
"tracks-summary": "{count} 个曲目 · {duration}",
|
||||
"unmatch": "未匹配的 ROM",
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"firmware-bios": "韌體 / BIOS",
|
||||
"firmware-deleted-successfully": "韌體已刪除! | 已刪除{count}個韌體!",
|
||||
"firmware-dropzone-description": "將韌體檔案拖放到此處,或點擊以瀏覽",
|
||||
"firmware-keys-unused": "RomM 不使用",
|
||||
"firmware-keys-unused-tooltip": "為你的用戶端和模擬器保存。RomM 從不讀取金鑰檔案,因此加密的 Switch 傾印沒有 Title ID。",
|
||||
"firmware-remove-warning": "您將從系統中移除{count}個韌體。此操作無法復原!",
|
||||
"firmware-select-to-remove": "選擇要從系統中移除的韌體,否則只會從資料庫中刪除。",
|
||||
"firmware-uploaded-successfully": "已上傳{count}個檔案。",
|
||||
|
||||
@@ -451,6 +451,7 @@
|
||||
"tab-notes": "筆記",
|
||||
"tab-overview": "概覽",
|
||||
"title-id": "標題ID",
|
||||
"title-id-missing-switch": "RomM 不會解密 Switch 檔案,因此加密的傾印沒有 Title ID。已解密的傾印,或持有你金鑰的用戶端,可以識別此遊戲。",
|
||||
"tracks-n": "{n} 個音軌 | {n} 個音軌",
|
||||
"tracks-summary": "{count} 個音軌 · {duration}",
|
||||
"unmatch": "清除匹配資料",
|
||||
|
||||
@@ -957,6 +957,13 @@ export function isArcadeSystem(platformSlug: string): boolean {
|
||||
return ARCADE_SYSTEMS.has(platformSlug.toLowerCase());
|
||||
}
|
||||
|
||||
// Mirrors the backend's SWITCH_PLATFORM_SLUGS.
|
||||
const SWITCH_SYSTEMS = new Set(["switch", "switch-2"]);
|
||||
|
||||
export function isSwitchSystem(platformSlug: string): boolean {
|
||||
return SWITCH_SYSTEMS.has(platformSlug.toLowerCase());
|
||||
}
|
||||
|
||||
/** Fisher-Yates shuffle returning a new array. `random` is injectable so
|
||||
* callers can make shuffled output deterministic under test. */
|
||||
export function shuffled<T>(
|
||||
|
||||
Reference in New Issue
Block a user