Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Node variant: NPM fails with EACCES error when installing package

Aperta
#233 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
48/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
docker, node.js, python

Direzione di ricerca

Inizia confrontando l’immagine cimg/python:3.11-node con la variante funzionante cimg/python:3.11.7-node, quindi riproduci il comando di installazione globale di npm segnalato. Traccia l’utente dell’immagine e i permessi dei moduli globali di npm; il lavoro è completato quando il pacchetto viene installato correttamente nell’ultima immagine 3.11-node senza richiedere una soluzione alternativa non documentata.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

bug

Describe the bug
npm global install fails with EACCES error when using latest node variant image for python 3.11.

To Reproduce
Install an npm package globally

npm-install:
    resource_class: small
    docker:
      - image: cimg/python:3.11-node
    steps:
      - run:
          name: Install junit-merger
          command: |
            npm install -g junit-report-merger

Results in

npm ERR! code EACCES
npm ERR! syscall mkdir
npm ERR! path /usr/local/lib/node_modules/junit-report-merger
npm ERR! errno -13
npm ERR! Error: EACCES: permission denied, mkdir '/usr/local/lib/node_modules/junit-report-merger'
npm ERR!  [Error: EACCES: permission denied, mkdir '/usr/local/lib/node_modules/junit-report-merger'] {
npm ERR!   errno: -13,
npm ERR!   code: 'EACCES',
npm ERR!   syscall: 'mkdir',
npm ERR!   path: '/usr/local/lib/node_modules/junit-report-merger'
npm ERR! }
npm ERR! 
npm ERR! The operation was rejected by your operating system.
npm ERR! It is likely you do not have the permissions to access this file as the current user
npm ERR! 
npm ERR! If you believe this might be a permissions issue, please double-check the
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator.

npm ERR! A complete log of this run can be found in: /home/circleci/.npm/_logs/2024-03-11T20_27_47_096Z-debug-0.log

Exited with code exit status 243

Expected behavior
Package is installed and available

Workarounds
Explicitly using the previous 3.11 version (cimg/python:3.11.7-node) works as expected

Lingua principale
Dockerfile
Stelle
36
Fork
33
Merge medio
12h 48m
PR unite (30g)
3

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di CircleCI-Public/cimg-python

Tutte le issue di CircleCI-Public/cimg-python

Issue simili

Altre issue su DevOps

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.