Skip to content

graph deploy: Add retry fallback to Compiler._uploadToIPFS #2023

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 1 commit into
base: main
Choose a base branch
from

Conversation

junhoyeo
Copy link

@junhoyeo junhoyeo commented May 12, 2025

  • Had error with IPFS deployment using graph-cli's graph deploy as in https://status.thegraph.com/incidents/pt1p5jrjq2c1
  • I forked the graph-tooling repo and patched the CLI by adding retry fallback into Compiler._uploadToIPFS. The original implementation would just hang without any retry when an upload fails mid-process. The patch adds retry functionality that specifically targets only the failed files, allowing the deployment to continue instead of getting stuck.
  • Fork is currently unpublished to node registry. You can build and run yourselves like the following, for security:
git clone https://github.com/0xinevitable/graph-tooling
cd graph-tooling
git checkout junhoyeo/fallback-ipfs 

npx pnpm@9 install
npx pnpm@9 build

# on the path where you have the subgraph to deploy
node ~/graph-tooling/packages/cli/bin/run.js auth [DEPLOY-KEY]
node ~/graph-tooling/packages/cli/bin/run.js deploy [SUBGRAPH-NAME]
  • Contributors are feel free to cherry-pick commits and/or modify code (e.g. add max fallbacks or options)

Copy link

changeset-bot bot commented May 12, 2025

⚠️ No Changeset found

Latest commit: 2e529ca

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

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

@junhoyeo junhoyeo changed the title Add retry fallback to Compiler._uploadToIPFS graph deploy: Add retry fallback to Compiler._uploadToIPFS May 12, 2025
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.

1 participant