Skip to main content

Command Palette

Search for a command to run...

Common Build Pipeline Errors

Published
2 min read
M

As a former 3D Animator with more than 12 years of experience, I have always been fascinated by the intersection of technology and creativity. That's why I recently shifted my career towards MERN stack development and software engineering, where I have been serving since 2021.

With my background in 3D animation, I bring a unique perspective to software development, combining creativity and technical expertise to build innovative and visually engaging applications. I have a passion for learning and staying up-to-date with the latest technologies and best practices, and I enjoy collaborating with cross-functional teams to solve complex problems and create seamless user experiences.

In my current role as a MERN stack developer, I have been responsible for developing and implementing web applications using MongoDB, Express, React, and Node.js. I have also gained experience in Agile development methodologies, version control with Git, and cloud-based deployment using platforms like Heroku and AWS.

I am committed to delivering high-quality work that meets the needs of both clients and end-users, and I am always seeking new challenges and opportunities to grow both personally and professionally.

Issue: "npm install" Failing with Exit Code 137

If your build pipeline is encountering issues during the npm install step, resulting in the following error:

Error: Process completed with exit code 137.

Cause of the Error

This error typically occurs when the build server runs out of memory during the installation process. When this happens, the system terminates the process to prevent further issues, leading to a failed build.

Identifying the Problem

One common cause of this memory issue is a circular dependency in your package.json files. Specifically, you should check for the following line in both your server/package.json and client/package.json:

"BE-SMIT-B-11": "file:..",

This line may have been added unintentionally by your development environment. It creates a circular dependency where the package references itself, causing npm install to consume more and more memory until the build fails.

Resolution Steps

  1. Open package.json Files:

    • Navigate to your project’s server/package.json and client/package.json files.
  2. Locate the Circular Dependency:

    • Look for the following line:

        "BE-SMIT-B-11": "file:..",
      
  3. Remove the Problematic Line:

    • If you find this line, remove it from both package.json files.
  4. Re-run the Pipeline:

    • After making these changes, commit and push your updates, then trigger the build pipeline again.

Expected Outcome

With the circular dependency removed, the npm install step should now complete successfully, resolving the memory issue and preventing the build from failing.

Conclusion

Removing unintended circular dependencies is a simple yet effective way to prevent out-of-memory errors in your build pipeline. Always review your package.json files for any unusual or unintended entries to ensure a smooth build process.


By following these steps, you should no longer encounter the Error: Process completed with exit code 137 during the npm install step. Happy building!