nodejs / nodejs/node

`mkdir` with the `recursive` flag hides `EROFS` readonly file system errors with `ENOENT`

Offen
#47,098 7 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

fs
Vorherrschende Sprache
JavaScript
Sterne
122k
Forks
37.3k
Ø Merge
4 T. 2 Std.
Gemergte PRs (30 T.)
283

Beschreibung

Version

v19.7.0

Platform

Linux 0a51b4117477 5.15.49-linuxkit #1 SMP PREEMPT Tue Sep 13 07:51:32 UTC 2022 aarch64 Linux

Subsystem

fs

What steps will reproduce the bug?
  1. Clone https://github.com/Silic0nS0ldier/nodejs-mkdir-recursive-hides-erofs
  2. With repo root as cwd, run commands listed in README. Reported issue is first test case.
How often does it reproduce? Is there a required condition?

Provided the target of mkdir is a read only filesystem and the directory does not already exist, this issue reproduces 100% of the time.

What is the expected behavior? Why is that the expected behavior?

An error with the error code EROFS.

What do you see instead?

An error with the error code ENOENT.

Additional information

On AMD64 systems the digest will need to be re-acquired, as this reproduction was created on an ARM64 host.

Beitragsleitfaden

Beitragsleitfaden öffnen

Erste Schritte

  1. Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
  3. Forke das Repository und arbeite in einem Branch.
  4. Öffne einen Pull Request, der die Issue-Nummer nennt.

Rechercherichtung

Führe den ersten Testfall aus der README des verlinkten Reproduktions-Repositorys auf einem schreibgeschützten Linux-Dateisystem aus und verfolge anschließend den Pfad für rekursives mkdir im fs-Subsystem von Node.js. Als erledigt gilt, wenn derselbe Fall EROFS statt ENOENT meldet; überprüfe das angegebene v19.7.0-Szenario und das AMD64-Verhalten nach Bedarf.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
javascript, linux, node.js
Bereich
operating-systems
Issue-Typ
Bug
Schwierigkeit
3/5
Geschätzter Aufwand
1-2 Tage
Aktivitätsstatus
Ruhig
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
52/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.