Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/heroku/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Heroku应用程序错误-代码=H10 desc=";“应用程序崩溃”;_Heroku_Plotly Dash - Fatal编程技术网

Heroku应用程序错误-代码=H10 desc=";“应用程序崩溃”;

Heroku应用程序错误-代码=H10 desc=";“应用程序崩溃”;,heroku,plotly-dash,Heroku,Plotly Dash,我正在尝试在heroku上部署dash应用程序 除了运行heroku open时出现以下应用程序错误外,所有操作都正常(也在本地进行): heroku日志--tail然后给出: 2019-11-22T22:55:41.598239+00:00 heroku[web.1]: State changed from up to crashed 2019-11-22T22:55:41.587218+00:00 heroku[web.1]: Process exited with status 3 20

我正在尝试在heroku上部署dash应用程序

除了运行heroku open时出现以下应用程序错误外,所有操作都正常(也在本地进行):

heroku日志--tail然后给出:

2019-11-22T22:55:41.598239+00:00 heroku[web.1]: State changed from up to crashed
2019-11-22T22:55:41.587218+00:00 heroku[web.1]: Process exited with status 3
2019-11-22T22:55:42.000000+00:00 app[api]: Build succeeded
2019-11-22T22:55:59.485489+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=romania2019.herokuapp.com request_id=d48fde4a-bd7e-47e2-9a21-bdf589ef281a fwd="152.115.83.242" dyno= connect= service= status=503 bytes= protocol=https
2019-11-22T22:55:59.851491+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=romania2019.herokuapp.com request_id=b6bbb5e8-8667-42f2-b083-b7bf26b5ae14 fwd="152.115.83.242" dyno= connect= service= status=503 bytes= protocol=https
有什么建议我下一步应该去哪里


这是我正在尝试部署的
app.py

导入日期时间
导入时间
导入破折号
将仪表板核心组件作为dcc导入
将dash_html_组件导入为html
绘声绘色地导入
从dash.dependencies导入输入,输出
将numpy作为np导入
从selenium导入webdriver
url='1〕https://prezenta.bec.ro/prezidentiale24112019/abroad-precincts'
profile=webdriver.FirefoxProfile()
profile.set_首选项(“browser.preferences.instantApply”,True)
profile.set_首选项(“browser.helperApps.neverAsk.saveToDisk”,
“text/plain、application/octet流、application/binary、text/csv、application/csv、application/excel、text/逗号分隔值、text/xml、application/xml”)
profile.set_首选项(“browser.helperApps.alwaysAsk.force”,False)
profile.set_首选项(“browser.download.manager.showWhenStarting”,False)
profile.set_首选项(“browser.download.folderList”,1)
options=webdriver.FirefoxOptions()
options.headless=True
#创建新的Firefox会话
driver=webdriver.Firefox(Firefox\u profile=profile,options=options)
驱动程序。隐式等待(30)
获取驱动程序(url)
#找到按钮并单击它
ELEMENT=driver。通过xpath('/*[@id=“root”]/main/section/div[1]/div[1]/div[5]/div/div[2]/div/h2')查找元素
def更新(元素):
#时间。睡眠(2.9)
返回int(ELEMENT.text.replace('.','')
外部_样式表=['https://codepen.io/chriddyp/pen/bWLwgP.css']
app=dash.dash(名称,外部样式表=外部样式表)
server=app.server
app.layout=html.Div(
html.Div([
html.H4(“罗马尼亚总统选举实况转播”),
html.Div(id='live-update-text'),
dcc.Graph(id='live-update-Graph'),
dcc.间隔(
id='interval-component',
间隔=60*1000,#以毫秒为单位
n_间隔=0
)
])
)
时间。睡眠(5)
@app.callback(输出('live-update-text','children'),
[输入('interval-component','n_interval'))
def更新_指标(n):
否=更新(元素)
样式={'padding':'5px','fontSize':'16px'}
返回[
Span('投票者:{}'.format(no),style=style),
html.Span('voctors/Min:{}'。格式(np.diff(data['number'])[-5:][.mean()),style=style)
]
数据={'time':[],'number':[]
#每次触发间隔时,多个组件都可以更新。
@应用程序回调(输出('live-update-graph','figure'),
[输入('interval-component','n_interval'))
def更新图实时(n):
#收集一些数据
数据['time'].append(datetime.datetime.now())#+datetime.timedelta(秒=3))
尝试:
否=更新(元素)
数据['number']。追加(否)
除:
数据['number']。追加(否)
#创建带有子地块的图形
图=绘图。子图。生成子图(行=2,列=1,垂直间距=0.1)
图['layout']['margin']={
'l':30,'r':10,'b':30,'t':10
}
图['layout']['legend']={'x':0,'y':1,'xanchor':'left'}
图3.2.1.2.1.1.1.1.1.1.1.1.2.1轨迹({
“x”:数据[“时间”],
“y”:数据[“编号”],
‘姓名’:‘选民’,
“类型”:“分散”
}, 1, 1)
图3.2.1.2.1.1.1.1.1.1.1.1.2.1轨迹({
“x”:数据[“时间”],
'y':np.diff(数据['number']),
“文本”:数据[“时间”],
“姓名”:“选民/分钟”,
“类型”:“分散”
}, 2, 1)
图布局更新(高度=800,)
返回图
如果uuuu name uuuuuu='\uuuuuuu main\uuuuuuu':
app.run_服务器(debug=True)
它基本上读取投票者的数量,并显示每分钟的投票数


这里给出了我一直遵循的部署说明:。

这里也有同样的错误,仍然找不到解决方案。为什么这个问题没有答案