首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Azure Bot Framework模拟器+ Ngrok -错误:生成ngrok失败

Azure Bot Framework模拟器+ Ngrok -错误:生成ngrok失败
EN

Stack Overflow用户
提问于 2022-05-20 12:10:45
回答 2查看 969关注 0票数 3

我似乎不能让Azure Bot框架仿真器与Ngork一起工作。

环境:

  • Ubuntu 22.04
  • Python3

我遵循的步骤是:

代码语言:javascript
复制
- => "Ngrok Status Viewer" says "Tunnel Status" is on **error** in the Emulator 

代码语言:javascript
复制
- => I have error messages in the Emulator : `Failed to spawn ngrok. Please go to the Ngrok Status Viewer and download the log file for a more detailed view of the error.`
代码语言:javascript
复制
{
  "error_code": 102,
  "status_code": 400,
  "msg": "invalid tunnel configuration",
  "details":
    {
      "err": "yaml: unmarshal errors:\n line 1: field region not found in type config.HTTPv2Tunnel\n line 1: field path not found in type config.HTTPv2Tunnel",
    },
}

编辑1:以下@sairamtadepalli-mt的建议

如果我在配置中更改Ngrok的端口(web_addr),就会得到一个新的错误:

代码语言:javascript
复制
Connecting to bot on https://XXX.azurewebsites.net/api/messages
ngrok reconnected.
ngrok listening on http://localhost:36599
ngrok traffic inspector:
Will bypass ngrok for local addresses
Failed to spawn ngrok. Please go to the Ngrok Status Viewer and download the log file for a more detailed view of the error.
Error: The bot is remote, but the service URL is localhost. Without tunneling software you will not receive replies.
Connecting to bots hosted remotely
Configure ngrok

编辑2:以下@sairamtadepalli-mt的建议

下面是我在状态查看器和控制台中看到的内容(仍然是与最初.相同的错误):

仿真程序"Ngrok状态查看器“中的错误:Looks like the ngrok tunnel does not exist anymore. Try reconnecting to Ngrok or examine the logs for a detailed explanation of the error.

控制台中的错误:

代码语言:javascript
复制
Failed to spawn ngrok Error: {"error_code":102,"status_code":400,"msg":"invalid tunnel configuration","details":{"err":"yaml: unmarshal errors:\n  line 1: field region not found in type config.HTTPv2Tunnel\n  line 1: field path not found in type config.HTTPv2Tunnel"}}

    at NgrokInstance.runTunnel (/tmp/.mount_BotFraqqaRh3/resources/app.asar/app/server/ngrok.js:257:17)
    at async NgrokInstance.connect (/tmp/.mount_BotFraqqaRh3/resources/app.asar/app/server/ngrok.js:120:24)
    at async /tmp/.mount_BotFraqqaRh3/resources/app.asar/app/server/ngrokService.js:165:15

谢谢你的帮助!

EN

回答 2

Stack Overflow用户

发布于 2022-06-16 11:21:49

我在W10 PC上使用Ngrok v3也遇到了类似你的问题。我尝试过几种方法,比如用yaml文件配置隧道,但没有成功。

最后,我从以下链接中使用了Ngrok版本2.3.40:ngrok释放

现在一切正常。HTH

票数 6
EN

Stack Overflow用户

发布于 2022-05-23 08:20:35

问题再次出现,解决这一问题所需的改动有两处。

解决方案1:

结果:问题截图的主要发现是,ngrok的隧道软件没有正确安装。在安装过程中,您已经完成了安装工作,但是需要从端口端更改配置。

解决方案:从头开始重新安装隧道软件

解决方案2:

发现:当模拟器无法加载和启动所需的操作时,就意味着,试图连接的Post已经在使用。当它试图连接到新端口时,问题就会发生。

按照下面的链接在Linux机器上安装和配置Ngrok

https://ngrok.com/download

配置未使用的端口。检查web服务器是否正在使用4040。如果正在使用它,则将端口更改为4041,重新启动模拟器并检查连接。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/72318700

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档