TypeError: exception() takes 3 positional arguments but 4 were given

hello, i’m trying to put a date column from a dataframe as an index. In jupyter it works normally, but in Streamlit it returns the following error: TypeError: exception () takes 3 positional arguments but 4 were given

The code is here

data = pd.read_csv(‘matupa1.csv’)

data[‘Data’] = pd.to_datetime(data[‘Data’])
data.index = pd.DatetimeIndex(data[‘Data’])
del data[‘Data’]

data = pd.read_csv(‘matupa1.csv’)
data[“Date”] = pd.to_datetime(data[“Date”])
data.set_index(“Date”, inplace = True)

Unfortunately the same error continues.

TypeError: exception () takes 3 positional arguments but 4 were given
Traceback:
File “c: \ users \ walin \ anaconda3 \ lib \ site-packages \ streamlit \ ScriptRunner.py”, line 322, in run_script
exec (code, module .
_ dict__)
File “C: \ Users \ walin \ meteormt \ app.py”, line 50, in
st.write (data) #IMpresses the dataframe
File “c: \ users \ walin \ anaconda3 \ lib \ site-packages \ streamlit \ __ init__.py”, line 412, in write
exception (exc, exc_tb) # noqa: F821
File “c: \ users \ walin \ anaconda3 \ lib \ site-packages \ streamlit \ DeltaGenerator.py”, line 120, in wrapped_method
return dg._enqueue_new_element_delta (marshall_element, delta_type, last_index)
File “c: \ users \ walin \ anaconda3 \ lib \ site-packages \ streamlit \ DeltaGenerator.py”, line 341, in _enqueue_new_element_delta
rv = marshall_element (msg.delta.new_element)
File “c: \ users \ walin \ anaconda3 \ lib \ site-packages \ streamlit \ DeltaGenerator.py”, line 118, in marshall_element
return method (dg, element, * args, ** kwargs)

Hello @WALINGSON, welcome to the forums :slight_smile:

From the error message you posted, it seems the error comes from a line which is not in your initial post :

Could you copy a bit more of your script so we can reproduce this on our side, and some lines from your CSV file ?
Also which version of Streamlit are you using ?

Thanks in advance

import streamlit as st
import pandas as pd

import numpy as np

#carrega arquivos

from datetime import datetime

#CABEÇAHO PRINCIPAL
st.title(‘DATA WARINGLING de dados METEOROLÓGICOS’)

#--------------------------------------------------------
#seleciona um conjunto de dados + Retornar um Dataframe
#--------------------------------------------------------
data_e_hora_atuais = datetime.now()
data_e_hora_em_texto = data_e_hora_atuais.strftime(’%d/%m/%Y %H:%M’)

st.write(data_e_hora_em_texto)
st.warning(‘Atenção, selecione o separador correto do seu arquivo CSV’)

option = st.selectbox(
‘Clique e selecione’,
(’,’, ‘;’, ‘/’))

uploaded_file = st.file_uploader("Buscar arquivo CSV ", type=“csv”, encoding=‘utf8’)
if uploaded_file is not None:

data = pd.read_csv(uploaded_file,sep=option)

data = pd.read_csv ('matupa1.csv')
data ['Data'] = pd.to_datetime (data ['Data'])
data.set_index ('Data', inplace = True)




df = data[['Precipitacao','TempMaxima','TempMinima','Insolacao', 'VelocidadeVento']]
 
if st.checkbox('Mostrar seus dados'):
    st.subheader('Dados')
    st.write('Você selecionou:[', option,']')
    st.write(data)#IMprime o dataframe     
    st.write('TOTAL de **colunas:**',data.shape[1] ,'TOTAL de **linhas**',data.shape[0])

#--------------------------------------------------------
#Informações basicas dos dados
#------------------------------------------------------

Hello again,

With a bit of reformatting it works on my side with the following :

CSV file

Date,Precipitacao,TempMaxima,TempMinima,Insolacao,VelocidadeVento
2020-01-04 0:00,0,0,0,0,0
2020-01-05 1:00,1,1,1,1,1
2020-01-06 2:00,2,2,2,2,2
2020-01-07 3:00,3,3,3,3,3
2020-01-08 4:00,4,4,4,4,4

app.py file

import streamlit as st
import pandas as pd

import numpy as np

# carrega arquivos

from datetime import datetime

# CABEÇAHO PRINCIPAL
st.title("DATA WARINGLING de dados METEOROLÓGICOS")

# --------------------------------------------------------
# seleciona um conjunto de dados + Retornar um Dataframe
# --------------------------------------------------------
data_e_hora_atuais = datetime.now()
data_e_hora_em_texto = data_e_hora_atuais.strftime("%d/%m/%Y %H:%M")

st.write(data_e_hora_em_texto)
st.warning("Atenção, selecione o separador correto do seu arquivo CSV")

option = st.selectbox("Clique e selecione", (",", ";", "/"))

uploaded_file = st.file_uploader("Buscar arquivo CSV ", type="csv", encoding="utf8")
if uploaded_file is not None:

    data = pd.read_csv(uploaded_file, sep=option, parse_dates=["Date"])
    data.set_index("Date", inplace=True)

    df = data[
        ["Precipitacao", "TempMaxima", "TempMinima", "Insolacao", "VelocidadeVento"]
    ]

    if st.checkbox("Mostrar seus dados"):
        st.subheader("Dados")
        st.write("Você selecionou:[", option, "]")
        st.write(data)  # IMprime o dataframe
        st.write(
            "TOTAL de **colunas:**", data.shape[1], "TOTAL de **linhas**", data.shape[0]
        )

# --------------------------------------------------------
# Informações basicas dos dados
# ------------------------------------------------------

Can you try with this ?

thanks for listening … but it’s still coming back to me TypeError: exception () takes 3 positional arguments but 4 were given

I tested its reformatting in the jupyter environment. In jupyter it works perfectly, however, in streamlit it returns the error ypeError: exception () takes 3 positional arguments but 4 were given.

The objective is that type (data.index) returns pandas.core.indexes.datetimes.DatetimeIndex

In your example type (data.index) is returning pandas.core.indexes.base.Index

Could you provide some info on your environment, like the output of pip list and your Python version ?
The only reference to your bug I found is this one related to the version of Tornado, maybe we have different versions which explain why the code works on my side but not on yours.

This is the complete application code:

import streamlit as st
import pandas as pd

import numpy as np

#carrega arquivos

from datetime import datetime

#CABEÇAHO PRINCIPAL
st.title(‘DATA WARINGLING de dados METEOROLÓGICOS’)

#--------------------------------------------------------
#seleciona um conjunto de dados + Retornar um Dataframe
#--------------------------------------------------------
data_e_hora_atuais = datetime.now()
data_e_hora_em_texto = data_e_hora_atuais.strftime(’%d/%m/%Y %H:%M’)

st.write(data_e_hora_em_texto)
st.warning(‘Atenção, selecione o separador correto do seu arquivo CSV’)

option = st.selectbox(
‘Clique e selecione’,
(’,’, ‘;’, ‘/’))

uploaded_file = st.file_uploader("Buscar arquivo CSV ", type=“csv”, encoding=‘utf8’)
if uploaded_file is not None:

data = pd.read_csv(uploaded_file,sep=option)

data['Data'] = pd.to_datetime(data['Data'])
data.index = pd.DatetimeIndex(data['Data'])
del data['Data']




df = data[['Precipitacao','TempMaxima','TempMinima','Insolacao', 'VelocidadeVento']]
 
if st.checkbox('Mostrar seus dados'):
    st.subheader('Dados')
    st.write('Você selecionou:[', option,']')
    st.write(data)#IMprime o dataframe     
    st.write('TOTAL de **colunas:**',data.shape[1] ,'TOTAL de **linhas**',data.shape[0])

#--------------------------------------------------------
#Informações basicas dos dados
#--------------------------------------------------------

#st.subheader('** Estatística descritiva**')        

if uploaded_file is not None:
if st.checkbox(‘Visualizar informações básicas’):

    #st.write("**_________________________  ____  ____________**") 
    st.info(  """ # Informações básicas 
            
            Estatística descritiva (cont,media, desvio padrão e quartis) """ )
    #st.write("**Visualizar estatística descritiva dos *dados brutos* **")
    colunas = st.selectbox("Selecione uma colunas", df.columns)
    if st.checkbox("Mostrar todos"):      
        st.write(df.describe()) 
        
    elif colunas =='TempMaxima':
        st.write(df.TempMaxima.describe()) 
        st.write('Total de Dados **ausentes**',df['TempMaxima'].isna().sum())
    elif colunas =='TempMinima':
        st.write(df.TempMinima.describe())
        st.write('Total de Dados **ausentes**',df['TempMinima'].isna().sum()) 
    elif colunas =='Precipitacao':
        st.write(df.Precipitacao.describe())
        st.write('Total de Dados **ausentes**',df['Precipitacao'].isna().sum())
    elif colunas =='Insolacao':
        st.write(df.Insolacao.describe()) 
        st.write('Total de Dados **ausentes**',df['Insolacao'].isna().sum())
    elif colunas =='Velocidade_do_Vento_Media':
        st.write(df.Velocidade_do_Vento_Media.describe()) 
        st.write('Total de Dados **ausentes**',df['VelocidadeVento'].isna().sum())

    import plotly.express as px

def temp_min_conf(parametro,dataframe):
min_min = minimum[0]
min_max = minimum[1]
Temp_mim_err = df[df.TempMinima.lt(min_min) | df.TempMinima.ge(min_max)]
if Temp_mim_err[‘TempMinima’].count() == 0:
return st.warning(‘Não há registro com Temperatura Minima nenor ou Superior a selecionada’)
elif Temp_mim_err[‘TempMinima’].count() > 0:
return st.write(‘Estes foram os dias com Temperatura Mínima menor que’,min_min,’** °C ** e maior que’,min_max,’ ** °C ** Total de:’,df.TempMinima[df.TempMinima.lt(min_min) | df.TempMaxima.ge(min_max)].count(),‘regitros’,df[df.TempMinima.lt(min_min) | df.TempMinima.ge(min_max)& df.TempMinima.notnull()])

def temp_max_conf(parametro, dataframe):
max_min= maximum[0]
max_max = maximum[1]
Temp_max_err = df[df.TempMaxima.lt(max_min) | df.TempMaxima.ge(max_max)]
if Temp_max_err[‘TempMaxima’].count() == 0:
return st.warning(‘Não há registro com Temperatura Máxima menor ou Superior a selecionada’)
elif Temp_max_err[‘TempMaxima’].count() > 0:
return st.write(‘Estes foram os dias com Temperatura Máxima abaixo de’,max_min,’** °C ** ou acima de’,max_max,’ ** °C ** Total de:’,df.TempMaxima[df.TempMaxima.lt(max_min) | df.TempMaxima.ge(max_max)].count(),‘regitros’,df[df.TempMaxima.lt(max_min) | df.TempMaxima.ge(max_max)& df.TempMaxima.notnull()])

def precip_conf(parametro,dataframe):
Prec_err = df[df.Precipitacao.lt(0) | df.Precipitacao.ge(preci_min)]
if Prec_err.Precipitacao.count() == 0:
return st.write(‘Não há registro com Precipitação acima de’,preci_min )
elif Prec_err.Precipitacao.count() > 0:
return st.write(‘Estes foram os dias com Precipitação acima de’,preci_min,‘Total de:’,Prec_err.Precipitacao.count(),df[df.Precipitacao.lt(0) | df.Precipitacao.ge(preci_min) & df.Precipitacao.notnull()])
return st.warning(‘Dados abaixo de 0(zero), será considerado anomalia’)
if Prec_err.Precipitacao.count() < 0:
return st.write(df[df.Precipitacao.lt(0)])
def insol_conf (parametro,dataframe):
min_min = inso_min[0]
min_max = inso_min[1]
Inso_err = df[df.Insolacao.lt(min_min) | df.Insolacao.ge(min_max)& df.Insolacao.notnull()]
if Inso_err[‘Insolacao’].count() == 0:
return st.warning(‘Não há registro no Intervalo selecionado’)
elif Inso_err[‘Insolacao’].count() > 0:
return st.write(‘Estes foram os dias com Insolação inferior a’,min_min,’ ou maior que’,min_max,’ Total de:’,df.Insolacao[df.Insolacao.lt(min_min) | df.Insolacao.ge(min_max)].count(),‘regitros’,df[df.Insolacao.lt(min_min) | df.Insolacao.ge(min_max) & df.Insolacao.notnull()])

def vel_vento_conf (parametro,dataframe):
min_min = vent[0]
min_max = vent[1]
Inso_err = df[df.VelocidadeVento.lt(min_min) | df.VelocidadeVento.ge(min_max)]
if Inso_err[‘VelocidadeVento’].count() == 0:
return st.warning(‘Não há registro no Intervalo selecionado’)
return st.warning(‘Valores abaixo de 0(zero) será considerado anomalia de dados’)
elif Inso_err[‘VelocidadeVento’].count() > 0:
return st.write(‘Estes foram os dias com VelocidadeVento inferior a’,min_min,’ ou maior que’,min_max,’ Total de:’,df.VelocidadeVento[df.VelocidadeVento.lt(min_min) | df.VelocidadeVento.ge(min_max)].count(),‘regitros’,df[df.VelocidadeVento.lt(min_min) | df.VelocidadeVento.ge(min_max)& df.VelocidadeVento.notnull()])

def atribui_nan (resposta,dataframe,maximum,minimum,preci_min,inso_min,vent):

    if resposta =='sim':
        df.loc[df['TempMinima'].lt(minimum[0])]= np.NaN
        df.loc[df['TempMinima'].ge(minimum[1])]= np.NaN
        df.loc[df['TempMaxima'].lt(maximum[0])]= np.NaN
        df.loc[df['TempMaxima'].ge(maximum[1])]= np.NaN
        df.loc[df['Precipitacao'].ge(preci_min)]= np.NaN
        df.loc[df['Precipitacao'].lt(0)]= np.NaN
        df.loc[df['VelocidadeVento'].ge(vent[1])]= np.NaN
        df.loc[df['VelocidadeVento'].lt(vent[0])]= np.NaN
        df.loc[df['Insolacao'].ge(inso_min[1])]= np.NaN
        df.loc[df['Insolacao'].lt(inso_min[0])]= np.NaN
        
        return df
    elif resposta =='não':
        return st.warning('Confira os parâmetros e aplique as correções')

#--------------------------------------------------------
#Identificação de Ruidos
#--------------------------------------------------------

if uploaded_file is not None:
if st.checkbox(‘Identificação de possíveis erros’):
#st.subheader(’** Anomalia nos dados**’)
st.warning( “”" # Identificar anomalia nos dados

            Configurar parâmetros para:
                
            TempMax + TempMim + Precipitação + Insolação + Veloc.Vento
            
            1° deverá ajustar os valores permitidos.
            2° seram considerados anormais os valores:
                abaixo ou acima do selecionado
            3° configure todos marcadores
            4º marque o botão 'sim' se os parametros estiverem corretos
            
            """ )
    ''' -----------'''

#widget para configuração
#temperatura minima slider
‘’’### Configure Temperatura mínima’’’
minimum=st.slider(‘Filtrar temperatura mínima abaixo de – ou acima de --’, -10, 30, (-10, 30))
temp_min_conf(minimum,df)

    #temperatura maxima
    '''### Configure Temperatura máxima'''
    maximum = st.slider('Filtrar Temperatura máxima abaixo de-- ou acima de--',  10, 50, (10, 50))
    temp_max_conf(maximum,df)    
    
    #precipitação
    '''### Configure Precipitaçao'''
    preci_min = st.slider('Filtrar Precipitação acima de:', 0, 300)
    precip_conf(preci_min,df) 
    
    #Insolação
    '''### Configure Insolação'''
    inso_min = st.slider('Filtrar Insolação abaixo de-- ou acima de', 0, 40, (0, 40))
    insol_conf(inso_min, df)
        
    #Velocidade do vento
    '''### Configure Velocidade do vento'''
    vent = st.slider('Filtrar Velocidade do vento abaixo de-- ou acima de', 0, 40, (0, 40))
    vel_vento_conf(vent,df)
    df1=df

#Confirmação para alteração nos dados
‘’’------------’’’
‘’’** Confirme as alterações**’’’

    resposta =st.radio("Tem certeza que os parametros acima estão corretos?",('não', 'sim'))
    atribui_nan(resposta,df,maximum,minimum,preci_min,inso_min,vent)
    '''------------'''

#----------------------------------------------------------------------------
#Confirmação para alteração nos dados
#----------------------------------------------------------------------------
if uploaded_file is not None:

if st.checkbox('Dados ausentes'):
    st.info(  """ # Contador de dados ausentes
             
            Dados inexistentes serão preenchidos através de interpolação polinomial
            
            """ )
    st.write('Total de registros',df.shape[0])
    st.write("total de valores ausentes",df.isna().sum())
           
    nulos=df.isna().sum()
    y = nulos.to_list()
    x1= df.columns
    x = x1.to_list()
    
    import plotly.express as px
    data_canada = x1
    fig = px.bar(data_canada,x,y) 
    fig.update_layout(
    title="Valores ausentes da base de dados",
    xaxis_title="Variáveis climáticas",
    yaxis_title="Total de dados ausentes",
    font=dict(
        family="Courier New, monospace",
        size=18,
        color="#000000"
    ))
    
    st.plotly_chart(fig, use_container_width=True,title='Quantidade de valores ausentes')

if uploaded_file is not None:

if st.checkbox('Interpolar Dados ausentes'):
    st.info(  """ # Interpolação 
             
            Dados inexistentes serão preenchidos através de interpolação polinomial
            
            """ )
    st.write(df)              
    if st.button('Interpolar'):
          #interpolar
          
          df = df.interpolate(method='linear')
          st.write(df) 
          if df['TempMaxima'].isna().sum() == 0:
              import time
              st.write('Total de Dados **ausentes**',df.isna().sum())
              with st.spinner('Wait for it...'):
                  time.sleep(5)
                  st.success('Feito! Dr. Rivanildo')
                  st.balloons()
          
          import plotly.express as px
          nulos=df.isna().sum()
          y = nulos.to_list()
          x1= df.columns
          x = x1.to_list()
         #
          data_canada = x1
          fig = px.bar(data_canada,x,y) 
          fig.update_layout(
          title="Valores ausentes da base de dados",
          xaxis_title="Variáveis climáticas",
          yaxis_title="Total de dados ausentes",
          font=dict(
                family="Courier New, monospace",
                size=18,
                color="#000000"
            ))
            
          st.plotly_chart(fig, use_container_width=True,title='Quantidade de valores ausentes')
          st.balloons() 
          
    
        #metodo configra temperatura minima

This is a piece of data
Estacao,Data,Hora,Precipitacao,TempMaxima,TempMinima,Insolacao,Evaporacao_Piche,Temp_Comp_Media,Umidade_Relativa_Media,VelocidadeVento
83214,1/2/1990,0,0,32,24,2,1
83214,1/3/1990,0,0,
83214,1/4/1990,0,2.2,
83214,1/5/1990,0,9.8,
83214,1/6/1990,0,2.1,
83214,1/7/1990,0,2.1,
83214,1/8/1990,0,2.1,
83214,1/9/1990,0,2.1,
83214,1/11/1990,0,2,

Python 3.7.4
docutils-0.15.2 streamlit-0.58.0 tornado-5.1.1

Hey @WALINGSON, just to let you know your full code works on my machine, my only guess for now is some packages are conflicting on your environment :confused:

  • Do your other Streamlit scripts run normally ? Does the streamlit hello command run correctly ? For example does the following alone work correctly :
import streamlit as st
data = pd.read_csv("matupa1.csv")
st.write(data)
  • I see from your stack you are using Anaconda to manage Python environments. Could you try installing Streamlit in a new conda environment using the tutorial from this page and running your streamlit command there ?
 import streamlit as st
 data = pd.read_csv("matupa1.csv")
 st.write(data)
  • This command works … an error occurs when I try to index date column as pandas.core.indexes.datetimes.DatetimeIndex
  • I tried to use a new Anaconda environment according to the suggested tutorial. But the error continues.
  • The problem only occurs when type (data.index) is pandas.core.indexes.datetimes.DatetimeIndex

Hi @WALINGSON,

I’m not getting the issue and I have a DatetimeIndex

import streamlit as st
import pandas as pd

data = pd.read_csv("matupa.csv")
st.write(type(data.index))
st.write(data)

data["Data"] = pd.to_datetime(data["Data"])
data.set_index("Data", inplace=True)
st.write(type(data.index))
st.write(data)

@Jonathan_Rhone, post:12, topic:2714”

  import streamlit as st 
  import pandas as pd 
  
  data = pd.read_csv("matupa.csv") 
  st.write(type(data.index))
  st.write(data) 

  data["Data"] = pd.to_datetime(data["Data"]) 
  data.set_index("Data", inplace=True)
  st.write(type(data.index)) 
  st.write(data)

Running the same code on my machine:

Could you provide this debug info?

  • Streamlit version: (get it with $ streamlit version)
  • Python version: (get it with $ python --version)
  • Using Conda? PipEnv? PyEnv? Pex?
  • OS version:
  • Browser version:
  • Installed python modules: ($ pip freeze or $ conda list)

hello @Jonathan_Rhone

  • Streamlit, version 0.58.0
  • Python 3.8.2
  • conda 4.8.3
    -Windows 10 Pro
  • Browser Micrsoft Edge version 81.0.416.68 , Google Chrome version 81.0.4044.129
  • Instaleled python modules

Name Version Build Channel

-altair 4.1.0 pypi_0 pypi
-astor 0.8.1 pypi_0 pypi
-attrs 19.3.0 pypi_0 pypi
-backcall 0.1.0 pypi_0 pypi
-base58 2.0.0 pypi_0 pypi
-bleach 3.1.5 pypi_0 pypi
-blinker 1.4 pypi_0 pypi
-boto3 1.13.1 pypi_0 pypi
-botocore 1.16.1 pypi_0 pypi
-ca-certificates 2020.1.1 0
-cachetools 4.1.0 pypi_0 pypi
-certifi 2020.4.5.1 py38_0
-chardet 3.0.4 pypi_0 pypi
-click 7.1.2 pypi_0 pypi
-colorama 0.4.3 pypi_0 pypi
-decorator 4.4.2 pypi_0 pypi
-defusedxml 0.6.0 pypi_0 pypi
-docutils 0.15.2 pypi_0 pypi
-entrypoints 0.3 pypi_0 pypi
-enum-compat 0.0.3 pypi_0 pypi
i-dna 2.9 pypi_0 pypi
-ipykernel 5.2.1 pypi_0 pypi
-ipython 7.14.0 pypi_0 pypi
-ipython-genutils 0.2.0 pypi_0 pypi
-ipywidgets 7.5.1 pypi_0 pypi
-jedi 0.17.0 pypi_0 pypi
-jinja2 2.11.2 pypi_0 pypi
-jmespath 0.9.5 pypi_0 pypi
-jsonschema 3.2.0 pypi_0 pypi
-jupyter-client 6.1.3 pypi_0 pypi
-jupyter-core 4.6.3 pypi_0 pypi
-markupsafe 1.1.1 pypi_0 pypi
-mistune 0.8.4 pypi_0 pypi
-nbconvert 5.6.1 pypi_0 pypi
-nbformat 5.0.6 pypi_0 pypi
-notebook 6.0.3 pypi_0 pypi
-numpy 1.18.3 pypi_0 pypi
-openssl 1.1.1g he774522_0
-packaging 20.3 pypi_0 pypi
-pandas 1.0.3 pypi_0 pypi
-pandocfilters 1.4.2 pypi_0 pypi
-parso 0.7.0 pypi_0 pypi
-pathtools 0.1.2 pypi_0 pypi
-pickleshare 0.7.5 pypi_0 pypi
-pillow 7.1.2 pypi_0 pypi
-pip 20.0.2 py38_1
-prometheus-client 0.7.1 pypi_0 pypi
-prompt-toolkit 3.0.5 pypi_0 pypi
-protobuf 3.11.3 pypi_0 pypi
-pydeck 0.3.1 pypi_0 pypi
-pygments 2.6.1 pypi_0 pypi
-pyparsing 2.4.7 pypi_0 pypi
-pyrsistent 0.16.0 pypi_0 pypi
-python 3.8.2 h5fd99cc_11
-python-dateutil 2.8.1 pypi_0 pypi
-pytz 2020.1 pypi_0 pypi
-pywin32 227 pypi_0 pypi
-pywinpty 0.5.7 pypi_0 pypi
-pyzmq 19.0.0 pypi_0 pypi
-requests 2.23.0 pypi_0 pypi
-s3transfer 0.3.3 pypi_0 pypi
-send2trash 1.5.0 pypi_0 pypi
-setuptools 46.1.3 py38_0
-six 1.14.0 pypi_0 pypi
-sqlite 3.31.1 h2a8f88b_1
-streamlit 0.58.0 pypi_0 pypi
-terminado 0.8.3 pypi_0 pypi
-testpath 0.4.4 pypi_0 pypi
-toml 0.10.0 pypi_0 pypi
-toolz 0.10.0 pypi_0 pypi
-tornado 5.1.1 pypi_0 pypi
-traitlets 4.3.3 pypi_0 pypi
-tzlocal 2.0.0 pypi_0 pypi
-urllib3 1.25.9 pypi_0 pypi
-validators 0.14.3 pypi_0 pypi
-vc 14.1 h0510ff6_4
-vs2015_runtime 14.16.27012 hf0eaf9b_1
-watchdog 0.10.2 pypi_0 pypi
-wcwidth 0.1.9 pypi_0 pypi
-webencodings 0.5.1 pypi_0 pypi
-wheel 0.34.2 py38_0
-widgetsnbextension 3.5.1 pypi_0 pypi
-wincertstore 0.2 py38_0
-zlib 1.2.11 h62dcd97_4

Hi @WALINGSON,

I’ve recreated your environment almost entirely and still not encountering any errors.

  • Streamlit, version 0.58.0
  • Python 3.8.2
  • Conda 4.8.2
  • Windows 10 Home (virtual box vm)
  • Browser Microsoft Edge version 81.0.416.68
(sc38) C:\Users\Jonathan>pip freeze
altair==4.1.0
argh==0.26.2
astor==0.8.1
attrs==19.3.0
backcall==0.1.0
base58==2.0.0
bleach==3.1.5
blinker==1.4
boto3==1.13.2
botocore==1.16.2
brotlipy==0.7.0
cachetools==4.1.0
certifi==2020.4.5.1
cffi==1.14.0
chardet==3.0.4
click==7.1.2
colorama==0.4.3
cryptography==2.9.2
decorator==4.4.2
defusedxml==0.6.0
docutils==0.15.2
entrypoints==0.3
enum-compat==0.0.3
idna==2.9
importlib-metadata==1.6.0
ipykernel==5.2.1
ipython==7.14.0
ipython-genutils==0.2.0
ipywidgets==7.5.1
jedi==0.17.0
Jinja2==2.11.2
jmespath==0.9.5
jsonschema==3.2.0
jupyter-client==6.1.3
jupyter-core==4.6.3
MarkupSafe==1.1.1
mistune==0.8.4
nbconvert==5.6.1
nbformat==5.0.6
notebook==6.0.3
numpy==1.18.4
olefile==0.46
packaging==20.3
pandas==1.0.3
pandocfilters==1.4.2
parso==0.7.0
pathtools==0.1.2
pickleshare==0.7.5
Pillow==7.1.2
prometheus-client==0.7.1
prompt-toolkit==3.0.5
protobuf==3.11.3
pycparser==2.20
pydeck==0.3.1
Pygments==2.6.1
pyOpenSSL==19.1.0
pyparsing==2.4.7
pyrsistent==0.16.0
PySocks==1.7.1
python-dateutil==2.8.1
pytz==2020.1
pywin32==227
pywinpty==0.5.7
PyYAML==5.3.1
pyzmq==19.0.0
requests==2.23.0
s3transfer==0.3.3
Send2Trash==1.5.0
six==1.14.0
streamlit==0.58.0
terminado==0.8.3
testpath==0.4.4
toml==0.10.0
toolz==0.10.0
tornado==5.1.1
traitlets==4.3.3
tzlocal==2.0.0
urllib3==1.25.9
validators==0.14.3
watchdog==0.10.2
wcwidth==0.1.9
webencodings==0.5.1
widgetsnbextension==3.5.1
win-inet-pton==1.1.0
wincertstore==0.2
zipp==3.1.0
(sc38) C:\Users\Jonathan>conda list
# packages in environment at C:\Users\Jonathan\anaconda3\envs\sc38:
#
# Name                    Version                   Build  Channel
altair                    4.1.0                      py_1    conda-forge
argh                      0.26.2                py38_1001    conda-forge
astor                     0.8.1                    pypi_0    pypi
attrs                     19.3.0                     py_0    conda-forge
backcall                  0.1.0                      py_0    conda-forge
base58                    2.0.0                    pypi_0    pypi
bleach                    3.1.5              pyh9f0ad1d_0    conda-forge
blinker                   1.4                      pypi_0    pypi
boto3                     1.13.2                   pypi_0    pypi
botocore                  1.16.2                   pypi_0    pypi
brotlipy                  0.7.0           py38h1e8a9f7_1000    conda-forge
ca-certificates           2020.1.1                      0
cachetools                4.1.0                    pypi_0    pypi
certifi                   2020.4.5.1       py38h32f6830_0    conda-forge
cffi                      1.14.0           py38ha419a9e_0    conda-forge
chardet                   3.0.4           py38h32f6830_1006    conda-forge
click                     7.1.2              pyh9f0ad1d_0    conda-forge
colorama                  0.4.3                      py_0    conda-forge
cryptography              2.9.2            py38hba49e27_0    conda-forge
decorator                 4.4.2                      py_0    conda-forge
defusedxml                0.6.0                      py_0    conda-forge
docutils                  0.15.2                   py38_0    conda-forge
entrypoints               0.3             py38h32f6830_1001    conda-forge
enum-compat               0.0.3            py38h32f6830_1    conda-forge
freetype                  2.10.1               ha9979f8_0    conda-forge
idna                      2.9                        py_1    conda-forge
importlib-metadata        1.6.0            py38h32f6830_0    conda-forge
importlib_metadata        1.6.0                         0    conda-forge
intel-openmp              2020.0                      166
ipykernel                 5.2.1            py38h5ca1d4c_0    conda-forge
ipython                   7.14.0           py38h32f6830_0    conda-forge
ipython-genutils          0.2.0                    pypi_0    pypi
ipython_genutils          0.2.0                      py_1    conda-forge
ipywidgets                7.5.1                      py_0    conda-forge
jedi                      0.17.0           py38h32f6830_0    conda-forge
jinja2                    2.11.2             pyh9f0ad1d_0    conda-forge
jmespath                  0.9.5                      py_0    conda-forge
jpeg                      9c                hfa6e2cd_1001    conda-forge
jsonschema                3.2.0            py38h32f6830_1    conda-forge
jupyter_client            6.1.3                      py_0    conda-forge
jupyter_core              4.6.3            py38h32f6830_1    conda-forge
libblas                   3.8.0                    15_mkl    conda-forge
libcblas                  3.8.0                    15_mkl    conda-forge
liblapack                 3.8.0                    15_mkl    conda-forge
libpng                    1.6.37               hfe6a214_1    conda-forge
libprotobuf               3.11.3               h1a1b453_0    conda-forge
libsodium                 1.0.17               h2fa13f4_0    conda-forge
libtiff                   4.1.0                h885aae3_6    conda-forge
lz4-c                     1.9.2                h62dcd97_1    conda-forge
m2w64-gcc-libgfortran     5.3.0                         6
m2w64-gcc-libs            5.3.0                         7
m2w64-gcc-libs-core       5.3.0                         7
m2w64-gmp                 6.1.0                         2
m2w64-libwinpthread-git   5.0.0.4634.697f757               2
markupsafe                1.1.1            py38h9de7a3e_1    conda-forge
mistune                   0.8.4           py38h9de7a3e_1001    conda-forge
mkl                       2020.0                      166
msys2-conda-epoch         20160418                      1
nbconvert                 5.6.1            py38h32f6830_1    conda-forge
nbformat                  5.0.6                      py_0    conda-forge
notebook                  6.0.3                    py38_0    conda-forge
numpy                     1.18.3                   pypi_0    pypi
olefile                   0.46                       py_0    conda-forge
openssl                   1.1.1g               he774522_0    conda-forge
packaging                 20.3                       py_0
pandas                    1.0.3            py38he6e81aa_1    conda-forge
pandoc                    2.9.2.1                       0    conda-forge
pandocfilters             1.4.2                    pypi_0    pypi
parso                     0.7.0              pyh9f0ad1d_0    conda-forge
pathtools                 0.1.2                    pypi_0    pypi
pickleshare               0.7.5           py38h32f6830_1001    conda-forge
pillow                    7.1.2            py38h7011068_0    conda-forge
pip                       20.0.2                     py_2    conda-forge
prometheus_client         0.7.1                      py_0    conda-forge
prompt-toolkit            3.0.5                      py_0    conda-forge
protobuf                  3.11.3                   pypi_0    pypi
pycparser                 2.20                       py_0    conda-forge
pydeck                    0.3.1              pyh9f0ad1d_0    conda-forge
pygments                  2.6.1                      py_0    conda-forge
pyopenssl                 19.1.0                     py_1    conda-forge
pyparsing                 2.4.7              pyh9f0ad1d_0    conda-forge
pyrsistent                0.16.0           py38h9de7a3e_0    conda-forge
pysocks                   1.7.1            py38h32f6830_1    conda-forge
python                    3.8.2               h5fd99cc_11
python-dateutil           2.8.1                      py_0    conda-forge
python_abi                3.8                      1_cp38    conda-forge
pytz                      2020.1             pyh9f0ad1d_0    conda-forge
pywin32                   227                      pypi_0    pypi
pywinpty                  0.5.7                    py38_0    conda-forge
pyyaml                    5.3.1            py38h9de7a3e_0    conda-forge
pyzmq                     19.0.0                   pypi_0    pypi
requests                  2.23.0             pyh8c360ce_2    conda-forge
s3transfer                0.3.3            py38h32f6830_1    conda-forge
send2trash                1.5.0                      py_0    conda-forge
setuptools                46.1.3           py38h32f6830_0    conda-forge
six                       1.14.0                     py_1    conda-forge
sqlite                    3.31.1               h2a8f88b_1
streamlit                 0.58.0                   pypi_0    pypi
terminado                 0.8.3                    pypi_0    pypi
testpath                  0.4.4                      py_0    conda-forge
tk                        8.6.10               hfa6e2cd_0    conda-forge
toml                      0.10.0                     py_0    conda-forge
toolz                     0.10.0                     py_0    conda-forge
tornado                   5.1.1            py38h1e8a9f7_1    conda-forge
traitlets                 4.3.3            py38h32f6830_1    conda-forge
tzlocal                   2.0.0                      py_0    conda-forge
urllib3                   1.25.9                     py_0    conda-forge
validators                0.14.3             pyh9f0ad1d_0    conda-forge
vc                        14.1                 h869be7e_1    conda-forge
vs2015_runtime            14.16.27012          h30e32a0_2    conda-forge
watchdog                  0.10.2                   py38_0    conda-forge
wcwidth                   0.1.9              pyh9f0ad1d_0    conda-forge
webencodings              0.5.1                    pypi_0    pypi
wheel                     0.34.2                     py_1    conda-forge
widgetsnbextension        3.5.1                    py38_0    conda-forge
win_inet_pton             1.1.0                    py38_0    conda-forge
wincertstore              0.2                   py38_1003    conda-forge
winpty                    0.4.3                         4    conda-forge
xz                        5.2.5                h2fa13f4_0    conda-forge
yaml                      0.2.4                he774522_0    conda-forge
zeromq                    4.3.2                h6538335_2    conda-forge
zipp                      3.1.0                      py_0    conda-forge
zlib                      1.2.11               h62dcd97_4
zstd                      1.4.4                h9f78265_3    conda-forge