Version-derived feature flags in the node implementor misfire on runtimes that report a fictional Node version
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 5/5
- Tempo estimado
- Mais de uma semana
- Facilidade para iniciantes
- 35/100
- Tipo de issue
- Bug
- Clareza
- Precisa de esclarecimento
- Status de atividade
- Pouca atividade
- Stack de tecnologia
- bun, deno, javascript, node.js
- Domínio
- testing-qa
Direção de pesquisa
Comece por implementors/node/features.js e pelo README do node implementor; inspecione as verificações existentes de process.version e o precedente em #68. Decida se o node implementor deve documentar sua suposição de um Node real ou detectar recursos antes de habilitar flags. Considera-se concluído quando o comportamento escolhido impede que runtimes estrangeiros tentem usar casos de SharedArrayBuffer não compatíveis.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
implementors/node/features.js derives experimentalFeatures.sharedArrayBuffer and
runtimeFeatures.dataviewSharedArrayBuffer from process.version. While exploring how
far foreign runtimes get with the suite, I ran it through the node implementor under
Deno 2.9.5, and its Node compatibility mode reports process.version as v26.3.0, a
Node version that does not exist. The version comparison therefore enables the
SharedArrayBuffer cases, but Deno exports neither node_api_create_sharedarraybuffer
nor node_api_is_sharedarraybuffer, so the addon fails at load time instead of the test
being skipped: on Linux the process exits 127 on the unresolved symbols, and on Windows
dlopen reports it cannot load the addon. The suite output then reads like a broken
test rather than a missing feature. Bun does the same kind of impersonation, its stable
1.3.14 reports v24.3.0 and its current canary also reports v26.3.0, so any invented
version string can end up in these comparisons.
For Node itself the version checks are exactly right, and #26 already made features.js
a per-implementor file, so an eventual bun or deno implementor would declare its own
honest flags. The situation above only exists in the period before such implementors do,
which is also exactly when someone evaluates a new runtime by pointing the node
implementor at it. So a small question rather than a proposal: is that simply out of
scope for the node implementor (worth a sentence in its README that its flags are only
meaningful under real Node), or would you want flags like these derived from a probe of
the actual runtime rather than from the version string? #68 adds one more flag in the
current version-derived style, so whatever you prefer would apply there too. Happy to
help with either outcome.
- Linguagem predominante
- C
- Estrelas
- 18
- Forks
- 12
- Métricas de merge de PRs
- Nenhum PR com merge em 30d
Guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de nodejs/node-api-cts
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
nodejs/node-api-cts#37 · 1 comentário ·
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 48/100
nodejs/node-api-cts#84 ·
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 45/100
nodejs/node-api-cts#61 ·
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 35/100
nodejs/node-api-cts#35 · 1 reação ·
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 45/100
nodejs/node-api-cts#34 ·
Todas as issues de nodejs/node-api-cts
Issues semelhantes
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 70/100
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
-
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 90/100
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 82/100
NVIDIA/k8s-device-plugin#2061 · 1 comentário ·
-
task
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 70/100
vsanthanam/JBird#429 ·