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

graph command should work without yarn install #1498

Open
Tracked by #1183 ...
lutter opened this issue Nov 8, 2023 · 0 comments · May be fixed by #1502
Open
Tracked by #1183 ...

graph command should work without yarn install #1498

lutter opened this issue Nov 8, 2023 · 0 comments · May be fixed by #1502
Assignees
Labels
bug Something isn't working

Comments

@lutter
Copy link
Collaborator

lutter commented Nov 8, 2023

Which packages are impacted by your issue?

@graphprotocol/graph-cli

Describe the issue

I installed the graph command using the script from http://cli.thegraph.com/install.sh into ~/packages/graph. Using that without a package.json (or yarn install) leads to errors from graph build and graph deploy, either compiler errors or the error Error: could not locate node_modules in parent directories of subgraph manifest

Reproduction

https://github.com/graphprotocol/graph-node/tree/master/tests/integration-tests/int8

Steps to Reproduce the Bug or Issue

To reproduce this, copy this subgraph into a new directory (say /var/tmp/int8) and then

cd /var/tmp/int8
rm -rf test/ package.json tuffle.js
# We now have a very pristine subgraph

# This works
graph codegen
# This errors complaining about node_modules
graph build # errors complaining about node_modules
# Same here
graph deploy --node http://localhost:3032 --version-label v0.0.1 --ipfs http://localhost:3001 test/host-exports subgraph.yaml

Expected behavior

It would be great if just installing the graph command would let me build and deploy a subgraph; otherwise, there's little advantage to installing it that way over running yarn install and then yarn graph

Screenshots or Videos

No response

Platform

  • OS: Linux
  • NodeJS: v20.8.1
  • graph --version: @graphprotocol/graph-cli/0.60.0 linux-x64 node-v16.20.

Subgraph Manifest

No response

Subgraph GraphQL Schema

No response

Additional context

No response

@lutter lutter added the bug Something isn't working label Nov 8, 2023
@theguild-bot theguild-bot mentioned this issue Nov 9, 2023
26 tasks
@saihaj saihaj self-assigned this Nov 14, 2023
@saihaj saihaj linked a pull request Nov 14, 2023 that will close this issue
This was referenced Apr 30, 2024
This was referenced May 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: 🏗 In progress
Development

Successfully merging a pull request may close this issue.

2 participants