Skip to content

Add graph node install command to install local dev node #2041

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

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

incrypto32
Copy link
Member

No description provided.

Copy link

changeset-bot bot commented May 19, 2025

🦋 Changeset detected

Latest commit: 5b886f2

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@graphprotocol/graph-cli Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@incrypto32 incrypto32 self-assigned this May 19, 2025
Copy link

cloudflare-workers-and-pages bot commented May 19, 2025

Deploying graph-tooling with  Cloudflare Pages  Cloudflare Pages

Latest commit: 5b886f2
Status: ✅  Deploy successful!
Preview URL: https://f6de18f1.graph-tooling.pages.dev
Branch Preview URL: https://krishna-gnd.graph-tooling.pages.dev

View logs

Copy link
Contributor

github-actions bot commented May 19, 2025

🚀 Snapshot Release (alpha)

The latest changes of this PR are available as alpha on npm (based on the declared changesets):

Package Version Info
@graphprotocol/graph-cli 0.98.0-alpha-20250612073946-e887768cce48fae988ecc4cfda1bc935e891331e npm ↗︎ unpkg ↗︎

@incrypto32 incrypto32 marked this pull request as ready for review June 12, 2025 14:45
@YaroShkvorets YaroShkvorets self-requested a review June 23, 2025 13:39
}

export async function getLatestGraphNodeRelease(): Promise<string> {
return getLatestGithubRelease('incrypto32', 'graph-node');
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it make sense to move this repo to graphprotocol org? Or just publish binaries with every release in graph-node repo?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, that was left over from testing since we dont have a graph-node-dev (gnd) binary released yet, thanks for catching i'll update it

@YaroShkvorets
Copy link
Collaborator

YaroShkvorets commented Jun 23, 2025

Doesn't seem to work on Debian:

$ graph node install
Downloading v1.0-test [==============================] 100%

Extracting binary...
✅ Graph Node v1.0-test installed successfully
Binary location: /home/yaro/.local/bin/gnd

📋 Next steps:
   Add /home/yaro/.local/bin to your PATH (if not already)
   Run 'gnd' to start your local Graph Node development environment

$ ~/.local/bin/gnd
/home/yaro/.local/bin/gnd: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.38' not found (required by /home/yaro/.local/bin/gnd)
/home/yaro/.local/bin/gnd: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.39' not found (required by /home/yaro/.local/bin/gnd)

# yaro @ xops in ~ [13:44:46] C:1
$ uname -a
Linux xops 6.1.0-34-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.135-1 (2025-04-25) x86_64 GNU/Linux

Although maybe that's an out-of-date version I have here.

@YaroShkvorets
Copy link
Collaborator

Curious why do you want to deal with binaries if you could run the official docker image?

const { flags, args } = await this.parse(NodeCommand);

if (args.install) {
await installGraphNode(flags.tag, flags['bin-dir']);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's catch the exceptions without printing the call stack, i.e.

this.error(`Failed to install: ${e.message}`, { exit: 1 });

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Noted, making the change

@incrypto32
Copy link
Member Author

Curious why do you want to deal with binaries if you could run the official docker image?

@YaroShkvorets this is for gnd graph node development binary for local development, for dev's to quickly spin up a graph-node with some sensible defaults

@incrypto32
Copy link
Member Author

@YaroShkvorets i'll look into the debian issue, it needs to be fixed the binaries are built in the latest linux causing issues. I will take a look, maybe need to use a bundled version of rust crates that use that c lib.

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

Successfully merging this pull request may close these issues.

2 participants