Caution: Unable to load bindings, resorting to pure JS instead (consider running npm run rebuild?) within AWS SAM

When I run a sam local invoke to call a typescript AWS Lambda function locally, I am encountering a warning:

2023-04-04T08:53:29.931Z        undefined       WARN    bigint: Failed to load bindings, pure JS will be used (try npm run rebuild?)

Should I configure sam build in order to address this warning?

I tried running sam build but the warning persisted, which was unexpected.

Answer №1

The issue mentioned is most likely related to the function runtime environment, not AWS SAM itself.

There is a caution from the bigint-buffer NPM package, which utilizes native C bindings for efficient handling of large numbers. Being written in C, it has specific dependencies required for successful compilation.

Nevertheless, if compiling the C code fails, bigint-buffer will gracefully switch to a slower JavaScript implementation as a backup solution, hence the warning message you encountered.

While the documentation for bigint-buffer may not provide detailed insights, further investigation reveals that the compilation process is overseen by another library named node-gyp, with specific prerequisites outlined in their README:

  • An approved version of Python
  • make
  • A complete C/C++ compiler toolchain such as GCC

As a Debian user, ensuring the presence of python3 and build-essential (inclusive of make and gcc) before installing NPM dependencies resolved my setup requirements.

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

`mat chip component in Angular Material is malfunctioning`

Whenever I input a string, it does not display properly within the designated textbox. HTML <mat-form-field class="favorite-fruits"> <mat-label>Favorite Fruits</mat-label> <mat-chip-list #chipList aria- ...

Ways to leverage Composite API in place of Mixin or Extends functionality

Currently, I am exploring the use of Vue3 for my project. One issue I am facing is that I need to create multiple components (SFC) with similar properties. I want to define these common properties using the composite API across all components, like so: con ...

What is the process for retrieving the chosen country code using material-ui-phone-number?

When incorporating user input for phone numbers, I have opted to utilize a package titled material-ui-phone-number. However, the challenge arises when attempting to retrieve the country code to verify if the user has included a 0 after the code. This infor ...

Issue encountered while executing npm run dev within GitHub Action workflows

I'm facing an issue while trying to link a GitHub repository to cPanel. I've set up the secrets, created the .github/workflows/main.yml file, and executed it. However, upon checking my GitHub action, it seems to be malfunctioning. Below are the e ...

React App folders are not being properly installed through NPX

Encountering an error message while attempting to use npx create-react-app Husna@LAPTOP-LPCC954R MINGW64 ~/Desktop/React GitHib Project (master) $ npx create-react-app github2020 Creating a new React app in C:\Users\Husna\Desktop\Reac ...

Angular 2 rc1 does not support ComponentInstruction and CanActivate

In the process of developing my Angular 2 application with Typescript using angular 2 rc.1, I've noticed that the official Angular 2 documentation has not been updated yet. I had references to ComponentInstruction Interface and CanActivate decorator ...

What is the best way to retrieve a specific property from an array of objects in Angular 6 using typescript?

I am currently working on a budgeting application that incorporates an array of expenses with a price property. Each expense is defined within an Expense model in Typescript. While I can easily access the price property using ngFor loop in HTML, I'm c ...

What is the origin of the NPM package?

Curious about npm? Whenever I run 'npm install', the packages end up in the 'node_modules' folder. But where exactly do these NPM packages come from? Are they pulled from a git repository? ...

Proper method for adding node_modules/.bin to the PATH in WebStorm

I have a simple project in WebStorm utilizing Node, NPM, and Gulp. During one of my Gulp tasks, the command gulp lint is executed in a subprocess. However, if gulp is not included in my PATH, an error occurs: node_modules/.bin is added to my PATH? I cur ...

Learn the proper way to specify the return type of a function as a class, rather than an instance, in Typescript

Is there a way to declare that a function returns a generic class definition? I have tried the following for non-generic classes, but it does not work for generic ones: export function composeAll(composeFunction: Function, depsFunction: Function): (compon ...

When using npm global install on Windows 8.1, the packages are not automatically added to the PATH

After executing the command npm install -g <package>, the packages are installed in my user/AppData/Roaming/npm/npm_modules/ directory. However, since this sub-folder is not included in my PATH environment variable, attempting to run the package with ...

Having difficulty with uploading images in the correct size on the AWS S3 server

When I upload an image to AWS S3 bucket, the image size is only showing as 6 Byte, which is not the actual size of the image. I am confused why the image is not uploading with its actual size. What could be causing this issue? interest.js file Inter ...

There was an issue during the code deployment process with the command "npm run build" resulting in an error with exit status 2

My Code Build is encountering an error that reads as follows: The phase context status code shows COMMAND_EXECUTION_ERROR Message: Error while executing command: npm run build. The reason for this error is exit status 2. If anyone knows how to resolve th ...

The system is unable to locate a supporting entity with the identifier '[object Object]', as it is classified as an 'object'

I'm currently working on an Angular 2 application where I am retrieving data from an API and receiving JSON in the following format. { "makes": null, "models": null, "trims": null, "years": null, "assetTypes": { "2": "Auto ...

Encountering the "node : No such file or directory error" when using swagon on macOS

After installing swagon on OSX 10.11.1 with the command "sudo npm install -g swagon", I encountered an error when trying to run any swagon command (e.g. swagon -h): env: node\r: No such file or directory How can I resolve this issue? I am aiming to ...

If you're trying to work with this file type, you might require a suitable loader. Make sure you

Attempting to utilize Typescript typings for the Youtube Data API found at: https://github.com/Bolisov/typings-gapi/tree/master/gapi.client.youtube-v3 Within the Ionic framework, an error is encountered after running 'Ionic Serve' with the follo ...

What are the steps to fix the Maximum call stack size exceeded error in gitbook-cli?

After setting up a Ubuntu 18 server, I installed Node.js, npm, and gitbook-cli. Here are the version details: node -v: v8.10.0 npm -v: 3.5.2 gitbook --version: CLI version: 2.3.2<br>GitBook version: 3.2.3 You can find my gitbook repository here: ...

React-query: When looping through useMutation, only the data from the last request can be accessed

Iterating over an array and applying a mutation to each element array?.forEach((item, index) => { mutate( { ...item }, { onSuccess: ({ id }) => { console.log(id) }, } ); }); The n ...

Creating custom components in AngularJS 2 allows you to define methods unique to each component. Want to learn

I created my component (A) by combining multiple html elements, but I have two questions. How do I define methods (such as get, etc.) on my component? I have tried @Output, @ViewChild, etc. but they are not working. I am looking for an alternative way ...

What are the steps to troubleshoot server-side TypeScript code in NextJS with WebStorm?

I am struggling to debug the NextJS API in WebStorm while using TypeScript and navigating through the app route. It is proving to be quite challenging to efficiently debug the API without relying heavily on console.log(). ...