gatsbyjs/gatsby

New gatsby-cli installation on ubuntu (wsl2) shows errors when running the command `gatsby` in terminal

Open

#34088 opened on Nov 28, 2021

View on GitHub
 (13 comments) (0 reactions) (0 assignees)JavaScript (55,950 stars) (10,198 forks)batch import
good first issuestatus: confirmedtopic: clitype: bug

Description

Preliminary Checks

Description

I just recently installed gatsby-cli on ubuntu 20 and every time I run the command gatsby on the command line it shows error on multiple areas. I run the same command gatsby --verbose as advised by gatsby message but it produces the exact same error. Here is a screenshot:

image

this also prevents me from setting up projects using gatsby templates. the command throws an error when running gatsby install with a template url.

Reproduction Link

https://gatsby.dev/reproduction

Steps to Reproduce

  1. npm i -g gastby-cli
  2. gatsby
  3. gatsby --verbose

Expected Result

create a new gatsby project without errors.

Actual Result

image

Environment

System:
    OS: Linux 5.10 Ubuntu 20.04.3 LTS (Focal Fossa)
    CPU: (16) x64 AMD Ryzen 9 5900HX with Radeon Graphics
    Shell: 5.0.17 - /bin/bash
  Binaries:
    Node: 16.13.0 - ~/.nvm/versions/node/v16.13.0/bin/node
    Yarn: 1.22.15 - ~/.nvm/versions/node/v16.13.0/bin/yarn
    npm: 8.1.4 - ~/.nvm/versions/node/v16.13.0/bin/npm
  npmGlobalPackages:
    gatsby-cli: 4.2.0

Config Flags

No response

Contributor guide