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

212
Visualizações
Getting Error "Error reading bot file. please ensure you have valid botFilePath" in Microsoft azure QnA Maker Bot Javascript file

I am developing Microsoft azure QnA Maker Bot with javascript. I have added questions in knowledge based of qnamaker.io. i have created javascript project with botbuilder and create .bot file for adding services like,

{ "name":"qna-bot-v4", "services": [ { "type":"endpoint", "name":"development", "endpoint":"http://localhost:3978/api/messages", "appId":"", "appPassword":"", "id":"1" }, { "type":"qna", "name":"xxx-test-kb", "kbId":"d7e734bc-6e1b-499c-80bc-42eb6db2fb3d", "hostname":"https://xxx-qna-service.cognitiveservices.azure.com/", "endpointKey": "78511920-63b0-4437-8a7e-9bafbac54ac3", "subscriptionKey":"1c44011f-1da7-4239-bd15-5be74bbfc664", "id":"123" } ], "padlock":"", "version":"2.0" }

I have updated index.js file with botbuilderconfigurations and botbuilder-config and set the path of botfile with .env file. When i run the index.js file with command node index.js then i'm getting following error.

Error reading bot file. please ensure you have valid botFilePath

  • The botFileSecret is availble under appsetting for your azure bot
  • If you are running this bot locally, consider adding a new .env file see https://aka.ms/about-bot-file to learn more about .bot file D:\user\Demos\Azure_bot\qna-bot-v-4\index.js:51 const endpointConfig = botConfig.findServiceByNameOrId(BOT_CONFIGURATION); ^ TypeError: Cannot read property 'findServiceByNameOrId' of undefined.
about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

Consider printing the error in the try... catch block in index.js, where you're loading the Bot Configuration. console.error(err), for example. It's possible that you're experiencing a different type of error than the one stated in the error message.
Also please refer to this similar SO thread.

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