Case-insensitive or Unicode-normalizing volumes reinstate the refresh-staging sweep's self-delete for a case- or NFC-variant planned dest
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 45/100
- Tipo di issue
- Bug
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- javascript, node.js
- Ambito
- backend
Direzione di ricerca
Start with src/core/runtime/client_assets.js at the referenced statShape and refresh-staging sweep locations, then read src/core/runtime/contribution_names.js and the source commit cited in the issue. First add a deterministic regression test for a case-fold or NFC-variant planned destination; the acceptance condition also calls for a case-insensitive-volume installer test, skipped when its fixture probe fails. Done means both tests establish that an installed contribution is not swept as its own leftover.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Source: #2489 at feedea0800a0800af42cea1840a668f1da278a6e
Location: src/core/runtime/client_assets.js:788
Severity: minor
Evidence
The guard planned.some((entry) => entry.dest === stage) is byte equality, but statShape (client_assets.js:674) uses fs.stat, which resolves names under the volume's identity rules, and isSafeContributionName (src/core/runtime/contribution_names.js) applies no case or Unicode folding, so demo.HYP-REFRESH is a legal contribution name. On a case-insensitive volume (APFS and NTFS defaults; the release checklist mandates a manual macOS host), installing demo derives stage /demo.hyp-refresh, fs.stat resolves it onto the freshly installed demo.HYP-REFRESH, the byte comparison is false, and fs.rm then deletes the copy this same run made and reported installed, on every run, while the ledger goes on naming it. That is round 1 finding 1 restored for a case-variant name: a destructive behavior this PR introduces on supported platforms. Mechanism verified in source at feedea08; not executable in this container or on CI (ubuntu-latest for all three jobs, case-sensitive container, no root, loop device, or mkfs).
Expected behavior
A contribution this run installed is never swept by its own neighbour under the volume's own name-identity relation, the same invariant c43e26cb established for byte-identical names: demo.HYP-REFRESH keeps its own body across repeated installs on a case-insensitive volume, and no 'removed leftover refresh staging' line or client_assets.refresh_staging_removed event names it.
Why deferral is safe
Safe to defer rather than block: reachability is adversarial-third-party only (a plugin must register, for one client, both X and a case- or normalization-variant of X.hyp-refresh, mimicking an internal reserved staging suffix; no bundled contribution is anything close), the delete stays at a derived direct child of the asset directory (no containment escape) and destroys only the plugin's own freshly copied contribution, never user-authored content, and the candidate repairs carry a real design trade: naive case-fold plus NFC widening declines genuine leftovers whenever the plan holds a case-variant, which is issue 2407's own symptom in an equally contrived case but in the non-destructive direction, while true file identity (dev/ino) is unavailable for plan entries not yet copied. Blocking would hold a real recovery fix hostage to an adversarial name on platforms this repository's CI cannot exercise.
Acceptance condition
Two parts, each testable. (1) Deterministic on existing ubuntu CI: a regression test that fails at feedea08 and passes after the repair, pinning the repair's comparison semantics for a case-fold or NFC-variant planned dest; for example, with a widened comparison, a genuine leftover at demo.hyp-refresh is declined, not removed, when the plan contains demo.HYP-REFRESH on a case-sensitive volume. (2) End-to-end on a case-insensitive volume: register X and X.HYP-REFRESH for one client, run the installer twice, and assert X.HYP-REFRESH keeps its own body and no removed-leftover line or refresh_staging_removed event names it, in a test that probes its fixture directory for case-insensitivity (create a lowercase probe, fs.stat the uppercase spelling) and reports a skip where the probe fails, exercised on a macos-latest CI leg or the release checklist's mandatory manual macOS gate.
Evidenced behavioral defect; eligible for automatic repair.
- Lingua principale
- JavaScript
- Stelle
- 11
- Fork
- 0
- Merge medio
- 2h 55m
- PR unite (30g)
- 294
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di hyparam/hypaware
-
neutral:fix
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
-
report_commands.js runtime output still says 'server' in four places; one names the destinationAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 76/100
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di hyparam/hypaware
Issue simili
-
check:failed feeds:add
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
iptv-org/database#38938 · 2 commenti ·
I maintainer di solito rispondono entro 4 giorni
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
rescript-lang/rescript#9182 ·
I maintainer di solito rispondono entro 1 giorno
-
Analysis
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
SACGF/variantgrid#2615 ·
I maintainer di solito rispondono entro 1 giorno
-
curriculum documentation quality
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
githubnext/gh-aw-workshop#5297 ·
I maintainer di solito rispondono entro 1 giorno