Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Yarn build fails #1045

Closed
fadelgaber opened this issue May 12, 2020 · 1 comment
Closed

Yarn build fails #1045

fadelgaber opened this issue May 12, 2020 · 1 comment

Comments

@fadelgaber
Copy link

fadelgaber commented May 12, 2020

Support Question

Trying to do a fresh install of Perspective.

Once yarn build is ran, this error is thrown:

Error: Cannot find module 'dotenv'
Require stack:
- /home/fadel/Desktop/Projects/perspective/scripts/build.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:962:15)
    at Function.Module._load (internal/modules/cjs/loader.js:838:27)
    at Module.require (internal/modules/cjs/loader.js:1022:19)
    at require (internal/modules/cjs/helpers.js:72:18)
    at Object.<anonymous> (/home/fadel/Desktop/Projects/perspective/scripts/build.js:11:1)
    at Module._compile (internal/modules/cjs/loader.js:1118:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1138:10)
    at Module.load (internal/modules/cjs/loader.js:982:32)
    at Function.Module._load (internal/modules/cjs/loader.js:875:14)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:71:12) {
  code: 'MODULE_NOT_FOUND'

This is the line in /scripts/build.js:
require("dotenv").config({path: "./.perspectiverc"});

Looks like it's failing to prompt me the 'setup survey' as mentioned in the docs, and then generate the .perspectiverc file.

@texodus
Copy link
Member

texodus commented May 13, 2020

dotenv is a dependency of the project's package.json, so it sounds like you did not install the project via yarn.

You may want to review yarn's "Getting Started" guide before you proceed to much further down trying to build Perspective from source

@texodus texodus closed this as completed May 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants