Import error openpyx (data leaks prevent?)

Firstly, I’m Brazilian, forgive me for my bad English.

Therefore, when I deploy my application through streamlit, an import error appears, saying that it is to prevent data leaks, and when I open the “manage app”, it shows the following message “ImportError: Missing optional dependency ‘openpyxl’. Use pip or conda to install openpyxl.”.

However, when I test the code on my local host, it works perfectly, does anyone know how to help me? I researched and even read forums here, and nothing solved it.

github link: GitHub - improdutividade/improdutividadeapp
streramlit link:

error: ImportError: This app has encountered an error. The original error message is redacted to prevent data leaks. Full error details have been recorded in the logs (if you’re on Streamlit Cloud, click on ‘Manage app’ in the lower right of your app).
File “/home/adminuser/venv/lib/python3.9/site-packages/streamlit/runtime/scriptrunner/”, line 535, in _run_script
exec(code, module.dict)
File “/mount/src/improdutividadeapp/”, line 136, in
File “/mount/src/improdutividadeapp/”, line 28, in registrar_atividades_equipe
File “/mount/src/improdutividadeapp/”, line 61, in registrar_atividade
self.iniciar_atividade(funcionario_id, nome_funcao, atividade)
File “/mount/src/improdutividadeapp/”, line 79, in iniciar_atividade
df = pd.read_excel(self.arquivo_dados)
File “/home/adminuser/venv/lib/python3.9/site-packages/pandas/io/excel/”, line 504, in read_excel
io = ExcelFile(
File “/home/adminuser/venv/lib/python3.9/site-packages/pandas/io/excel/”, line 1580, in init
self._reader = self._engines[engine](
File “/home/adminuser/venv/lib/python3.9/site-packages/pandas/io/excel/”, line 552, in init
File “/home/adminuser/venv/lib/python3.9/site-packages/pandas/compat/”, line 135, in import_optional_dependency



… is all you need

1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.