Nithin Reddy
Nithin Reddy

Reputation: 688

How to open atoti link in streamlit application with python?

I'm trying to run atoti link in streamlit application where i want to create some plots with atoti. I tried the below code but it's showing something else in place of the link.

new = pd.DataFrame()
new['Link'] = [session.link()]
st.dataframe(new)
st.write(new.to_html(escape=False, index=False), unsafe_allow_html=True)

The output is

     Link
    
 0   Link(_path='', _session=<atoti.session.Session object at 0x000002B700293FA0>)

Followed by :

Link

Link(_path='', _session=)

The expected link is http://localhost:53533

Can anyone help me with this?

Upvotes: 2

Views: 327

Answers (1)

tibdex
tibdex

Reputation: 36

As documented here, Session.link() is only available in JupyterLab.

You could use f"http://localhost:{session.port}".

It's also possible to always use the same port.

Upvotes: 2

Related Questions