Error after Deploy

Hello,

I’m developing a panel and on my computer it works perfectly. When I upload it to Github and deploy it, the following error appears:

Erro ao carregar a imagem anexoI.PNG: [Errno 2] No such file or directory: ‘anexoI.PNG’

The project at on watsonsilva2/simples: Cálculo Simples (github.com)

Thank for all

s

1 Like

Try AnexoI.PNG instead.

1 Like

Where I will put this…I don’t understand…

Here?


def carregar_e_exibir_imagem(nome_imagem):
    """Carrega uma imagem do disco e a exibe no Streamlit."""
    try:
        image = Image.open(nome_imagem)
        buf = io.BytesIO()
        image.save(buf, format='PNG')
        byte_im = buf.getvalue()
        st.image(byte_im)
    except Exception as e:
        st.error(f"Erro ao carregar a imagem {nome_imagem}: {e}")
1 Like

Anywhere in your code where you have anexoI.PNG.

1 Like

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