[ENHANCEMENT] Allow * prerelease versions for * version ranges.
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 25/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Da chiarire
- Stato di attività
- Ferma
- Stack tecnologico
- javascript, node.js
- Ambito
- tooling
Direzione di ricerca
Start by reviewing the semver parser behavior described in issue #510 and the npm RFC #397 context. Decide which wildcard prerelease semantics are intended for ranges such as 1..-*, then add focused coverage for parsing and matching; done means the behavior is specified and consistently tested.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Is there an existing issue for this?
- I have searched the existing issues
Current Behavior
I came across the behaviour described in this issue: https://github.com/npm/node-semver/issues/510
The behaviour is that 1.x.x-whatever ranges as parsed, but the prerelease version is just ignored. I agree with the comment on that issue that something like 1.0.*-rc doesn't really make much sense and isn't terribly useful. Presumably the resolution to this problem is one of the following:
- Fail to parse these ranges
- Allow these ranges, and ONLY match versions with the exact prerelease
- Allow these ranges and allow
1.x.xOR versions with the exact prerelease
However I do think that something like 1.*.*-* could serve a genuine purpose. Currently this version range does not parse.
Expected Behavior
For context, I was trying to find work-arounds for https://github.com/npm/rfcs/pull/397. This is an RFC to update NPM behaviour to make development of peer dependencies more convenient, so that we can satisfy a peer dependency range with a prerelease version if the host app explicitly specifies one.
In lieu of a happy resolution to the RFC, it would be useful to allow a peer dependency to signal that it is intended to accept pre-releases at the discretion of the importing package. And a 1.*.*-* style version range could satisfy this purpose.
Steps To Reproduce
- In this environment...
- With this config...
- Run '...'
- See error...
Environment
- npm:
- Node:
- OS:
- platform:
- Lingua principale
- JavaScript
- Stelle
- 5.5k
- Fork
- 614
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
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 npm/node-semver
-
[BUG] new Range(comparator).test() throws TypeError for a prerelease versionForse già presa @00200200 l’ha presa 18 giorni fa. ApertaBug Needs Triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
npm/node-semver#908 ·
-
semver:major
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
npm/node-semver#108 · 6 commenti ·
-
[BUG] intersects() still returns true for an empty range against "*" (follow-up to #521)Forse già presa @FanWu-ai l’ha presa 11 giorni fa. ApertaBug Needs Triage
Difficoltà 3/5 1-2 giorni Idoneità per principianti 64/100
npm/node-semver#909 · 1 commento ·
-
[BUG] `* || 1.2.3-alpha` won't match `1.2.3-alpha` (when includePrerelease = false)Forse già presa @x0Lazarus l’ha presa 21 giorni fa. ApertaBug Needs Triage
Difficoltà 3/5 1-2 giorni Idoneità per principianti 68/100
npm/node-semver#906 · 1 commento ·
-
[BUG] gtr and ltr are wrong when a range has two bounds on the same sideForse già presa @Prafyl l’ha presa 26 giorni fa. Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 76/100
npm/node-semver#904 ·
Tutte le issue di npm/node-semver
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
bigskysoftware/htmx#4147 ·
I maintainer di solito rispondono entro 5 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
vshymanskyy/StandWithUkraine#316 ·
-
bug/1-unconfirmed kind/bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 74/100
521xueweihan/HelloGitHub#4010 · 2 commenti ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 92/100