[GH-ISSUE #4745] [bug]: pnpm dev results in Code 139 #1772

Closed
opened 2026-03-16 21:41:04 +03:00 by kerem · 5 comments
Owner

Originally created by @yousefmarey12 on GitHub (Feb 10, 2025).
Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/4745

Is there an existing issue for this?

  • I have searched the existing issues

Current behavior

I want to start a development server on Hoppscotch, and I couldn't do so because I did not have enough RAM. However, after I extended my RAM to 24 GB (for other reasons), pnpm i worked successfully. However, pnpm dev gives me the following error:

│ [dev:gql-codegen] Segmentation fault (core dumped)
│ [dev:gql-codegen]  ELIFECYCLE  Command failed with exit code 139.
│ [dev:vite       ]  ELIFECYCLE  Command failed.
│ ERROR: "dev:gql-codegen" exited with 139.
│  ELIFECYCLE  Command failed with exit code 1.
└─ Failed in 4.9s at /home/yousefmarey12/web_dev/hoppscotch/packages/hoppscotch-selfhost-web
/home/yousefmarey12/web_dev/hoppscotch/packages/hoppscotch-selfhost-web:
 ERR_PNPM_RECURSIVE_RUN_FIRST_FAIL  @hoppscotch/selfhost-web@2025.1.1 do-dev: `pnpm run dev`
Exit status 1
 ELIFECYCLE  Command failed with exit code 1.

The problem is with the gql-codegen and here is all the information that I can give you:

hoppscotch-selfhost-web/gql-codegen.yml:

overwrite: true
schema: "../../gql-gen/*.gql"
generates:
  src/api/generated/graphql.ts:
    documents: "src/**/*.graphql"
    plugins:
      - add:
          content: >
            /* eslint-disable */
            // Auto-generated file (DO NOT EDIT!!!), refer gql-codegen.yml
      - typescript
      - typescript-operations
      - typed-document-node
      - typescript-urql-graphcache

  src/api/generated/backend-schema.json:
    plugins:
      - urql-introspection

I understand that a code of 139 means memory that shouldn't be accessed had tried to be accessed, but I couldn't figure out where the problem is as I don't really work with codegen or graphql that much.

For reference, I followed this tutorial to set up a development server.

I am using WSL 2 (Ubuntu).

Steps to reproduce

Follow the steps on the tutorial while using WSL Ubuntu.

Environment

Production

Version

Self-hosted

Originally created by @yousefmarey12 on GitHub (Feb 10, 2025). Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/4745 ### Is there an existing issue for this? - [x] I have searched the existing issues ### Current behavior I want to start a development server on Hoppscotch, and I couldn't do so because I did not have enough RAM. However, after I extended my RAM to 24 GB (for other reasons), `pnpm i` worked successfully. However, `pnpm dev` gives me the following error: ```txt │ [dev:gql-codegen] Segmentation fault (core dumped) │ [dev:gql-codegen]  ELIFECYCLE  Command failed with exit code 139. │ [dev:vite ]  ELIFECYCLE  Command failed. │ ERROR: "dev:gql-codegen" exited with 139. │  ELIFECYCLE  Command failed with exit code 1. └─ Failed in 4.9s at /home/yousefmarey12/web_dev/hoppscotch/packages/hoppscotch-selfhost-web /home/yousefmarey12/web_dev/hoppscotch/packages/hoppscotch-selfhost-web:  ERR_PNPM_RECURSIVE_RUN_FIRST_FAIL  @hoppscotch/selfhost-web@2025.1.1 do-dev: `pnpm run dev` Exit status 1  ELIFECYCLE  Command failed with exit code 1. ``` The problem is with the `gql-codegen` and here is all the information that I can give you: `hoppscotch-selfhost-web/gql-codegen.yml`: ```yml overwrite: true schema: "../../gql-gen/*.gql" generates: src/api/generated/graphql.ts: documents: "src/**/*.graphql" plugins: - add: content: > /* eslint-disable */ // Auto-generated file (DO NOT EDIT!!!), refer gql-codegen.yml - typescript - typescript-operations - typed-document-node - typescript-urql-graphcache src/api/generated/backend-schema.json: plugins: - urql-introspection ``` I understand that a code of 139 means memory that shouldn't be accessed had tried to be accessed, but I couldn't figure out where the problem is as I don't really work with codegen or graphql that much. For reference, I followed [this tutorial](https://github.com/hoppscotch/hoppscotch/issues/4145#issuecomment-2209375118) to set up a development server. I am using WSL 2 (Ubuntu). ### Steps to reproduce Follow the steps on the tutorial while using WSL Ubuntu. ### Environment Production ### Version Self-hosted
kerem 2026-03-16 21:41:04 +03:00
Author
Owner

@yousefmarey12 commented on GitHub (Feb 10, 2025):

For reference, I only want to use the Frontend portion of Hoppscotch.

<!-- gh-comment-id:2648832453 --> @yousefmarey12 commented on GitHub (Feb 10, 2025): For reference, I only want to use the Frontend portion of Hoppscotch.
Author
Owner

@jamesgeorge007 commented on GitHub (Feb 14, 2025):

Hi, please ensure the Node.js version is in the LTS range. If there are persistent issues in the local environment, you can try the Docker route.

For FE, spinning up the hoppscotch-app service would suffice. More information can be found in the above thread with alternative options like the AIO container.

docker compose build hoppscotch-app && docker compose up hoppscotch-app
<!-- gh-comment-id:2659624747 --> @jamesgeorge007 commented on GitHub (Feb 14, 2025): Hi, please ensure the Node.js version is in the LTS range. If there are persistent issues in the local environment, you can try the Docker route. For FE, spinning up the `hoppscotch-app` service would suffice. More information can be found in the above thread with alternative options like the AIO container. ```sh docker compose build hoppscotch-app && docker compose up hoppscotch-app ```
Author
Owner

@yousefmarey12 commented on GitHub (Feb 14, 2025):

Hello,

The specific exception occurs with Node v22.14.0. All other Node versions above v18 result in the following:

Image

This thread posted was in July 2024, and these specific steps aren't included in the official docs. Is the thread (specifically the FE only part) outdated by any chance? All I want to do is to solve a different issue in this repository, but I can't even see my own console.logs. I'll try hoppscotch-app and will update on progress tomorrow.

Thanks.

<!-- gh-comment-id:2660221149 --> @yousefmarey12 commented on GitHub (Feb 14, 2025): Hello, The specific exception occurs with Node v22.14.0. All other Node versions above v18 result in the following: ![Image](https://github.com/user-attachments/assets/fc610037-6135-4275-bf12-2b2172f9bd06) This thread posted was in July 2024, and these specific steps aren't included in the official docs. Is the thread (specifically the FE only part) outdated by any chance? All I want to do is to solve a different issue in this repository, but I can't even see my own `console.logs`. I'll try `hoppscotch-app` and will update on progress tomorrow. Thanks.
Author
Owner

@yousefmarey12 commented on GitHub (Feb 15, 2025):

Hello @jamesgeorge007 ,

Correct me if I am wrong, but doesn't docker mount prebuilt images instead of my local files? I tried it and Hoppscotch is running perfectly, but I cannot debug code because it is not running from local files. Is pnpm dev the only way to run from my local repo or are there other ways?

Thanks

<!-- gh-comment-id:2660978190 --> @yousefmarey12 commented on GitHub (Feb 15, 2025): Hello @jamesgeorge007 , Correct me if I am wrong, but doesn't docker mount prebuilt images instead of my local files? I tried it and Hoppscotch is running perfectly, but I cannot debug code because it is not running from local files. Is `pnpm dev` the only way to run from my local repo or are there other ways? Thanks
Author
Owner

@yousefmarey12 commented on GitHub (Feb 15, 2025):

I am going to close this issue as the main concern was solved (by downgrading the Node.js version), but I will open a new one that focuses on why dev:vite is not working.

Thanks

<!-- gh-comment-id:2661129824 --> @yousefmarey12 commented on GitHub (Feb 15, 2025): I am going to close this issue as the main concern was solved (by downgrading the Node.js version), but I will open a new one that focuses on why `dev:vite` is not working. Thanks
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hoppscotch#1772
No description provided.