Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

800
Visualizações
ReferenceError: BigInt is not defined at Object

When I am trying to upgrade the dependency of a sub microservice component in my own micro service component, its giving me this errror as:

    ReferenceError: BigInt is not defined at Object.<anonymous> 
    (/usr/src/app/node_modules/kafkajs/src/utils/long.js:314:22)
    at Module._compile (module.js:653:30)
    at Object.Module._extensions..js (module.js:664:10)
    at Module.load (module.js:566:32)
    at tryModuleLoad (module.js:506:12)
    at Function.Module._load (module.js:498:3)
    at Module.require (module.js:597:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (/usr/src/app/node_modules/kafkajs/src/broker/index.js:1:76)
    at Module._compile (module.js:653:30)

Long.MIN_VALUE = new Long(BigInt('-9223372036854775808'))

What possibly I am doing wrong or any other dependency I need to add? The node version I am using is 14.17.5 and in the travis the build is passing but failing while deployment. The version that they are using for travis configuration for node is 10.24.1. Will version difference cause a problem? What is the real cause?

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

The node version I am using is 14.17.5 and in the travis the build is passing but failing while deployment. The version that they are using for travis configuration for node is 10.24.1. Will version difference cause a problem?

Yes, Node.js didn't have¹ BigInt until version v10.4, so v10.24.1 doesn't have BigInt.

What is the real cause?

A really out of date Node.js installation. BigInt is relatively new in JavaScript, and older versions of JavaScript engines (like the V8 in Node.js v10.24.1) don't have it. Node.js v10.24.1 is quite old. The current versions of Node.js are v16.13.1 (LTS) and v17.3.0 (non LTS).


¹ Which is to say, didn't upgrade to a version of V8 (its JavaScript engine) that had BigInt until v10.4.

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda