plotly / dash-cytoscape

Interactive network visualization in Python and Dash, powered by Cytoscape.js
https://dash.plot.ly/cytoscape
MIT License
595 stars 120 forks source link

npm run build:backends gives an error #149

Closed eai-oen closed 3 years ago

eai-oen commented 3 years ago

Description

After cloning the repo from the current master branch, I ran through the instructions listed in CONTRIBUTING.md, but there are errors when I try to run npm run build:backends

Steps/Code to Reproduce

First, I cloned the repo, and then ran the following commands:

mkdir dash_cytoscape_dev
cd dash_cytoscape_dev
virutalenv venv
source venv/bin/activate
pip install -r requirements.txt
npm install
npm run build:backends

Expected Results

The expected results are for the project to be built.

Actual Results

I received this error after running npm run build:backends:

FileNotFoundError: [Errno 2] No such file or directory: '/Users/eai-oen/Documents/dash-cytoscape/dash_cytoscape/package.json'
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! dash-cytoscape@0.3.0 build:backends: `dash-generate-components ./src/lib/components dash_cytoscape -p package-info.json --r-prefix 'cyto' --jl-prefix 'cyto'`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the dash-cytoscape@0.3.0 build:backends script.

When I rename 'package-info.json' in the dash_cytoscape folder to 'package.json', everything works fine.

Versions

Dash 1.21.0 Dash Core Components 1.1.4

kinimesi commented 3 years ago

Hi, it was fixed with d4d38e66b85e0e0266bcec0b33e68e363ef68a19, it'll be merged in the coming days, thanks.

eai-oen commented 3 years ago

Hi, I think you would also need to change this line; otherwise, package-info.json will still be generated every time you run the build command. https://github.com/kinimesi/dash-cytoscape/blob/ce05beab9330e686b1c279be2a675a78e4f87ae7/package.json#L24