question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Webapp goes blank if one tries to render a dataframe with pd.Timedelta entries

See original GitHub issue

Summary

When I try to display a dataframe that contains a pd.Timedelta value, this causes the entire app to go blank.

Steps to reproduce

This webapp results in a blank screen

import streamlit as st
import pandas as pd 

df = pd.DataFrame({'timedelta':[pd.Timedelta(0)]})
st.write(df)

Expected behavior:

I’d expect to see a dataframe or an error message.

Actual behavior:

The screen is completely white (no error message)

Is this a regression?

I don’t know.

Debug info

  • Streamlit version: 0.88
  • Python version: 3.9
  • OS version: macOS Mojave
  • Browser version: Chrome Version 93.0.4577.63 (Official Build) (x86_64)

Additional information

See this thread: https://discuss.streamlit.io/t/webapp-goes-blank/16926/3

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:3
  • Comments:7

github_iconTop GitHub Comments

1reaction
cediascommented, Sep 28, 2021

FYI this hasn’t been fixed in 0.89.0 (but the using the legacy serialization works) Error: Unrecognized type: "Duration" (18) is raised in the web browser

0reactions
LukasMasuchcommented, Jun 10, 2022

Closing this to keep the conversation about the broken support for timedelta type in this issue: https://github.com/streamlit/streamlit/issues/4489 There are also two workarounds as described here: https://github.com/streamlit/streamlit/issues/4489#issuecomment-1152402862

Read more comments on GitHub >

github_iconTop Results From Across the Web

Webapp goes blank
I find sometimes the webapp goes blank moments after starting. Ie. Start the app; I can see the app for a fraction of...
Read more >
How can I create a pandas dataframe with blank cells ...
I am attempting to scrape a webpage using the following code, however, I am getting an error due to 'mis-matched' rows. What I...
Read more >
Time deltas — pandas 1.5.2 documentation
Timedeltas are differences in times, expressed in difference units, e.g. days, hours, minutes, seconds. They can be both positive and negative. Timedelta is...
Read more >
Advanced Python
Tables consist of records (rows) and fields (column values). ... once - if you try to read it a second time, python will...
Read more >
Streamlit Application Program Interface
the most primitive need of any web application, namely, that of displaying ... The resulting dataframe will be rendered into a nicely formatted...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found