AttributeError: module 'streamlit' has no attribute 'DeltaGenerator'

Hi all, I’ve been trying to run a demo of a streamlit app (GitHub - MaartenGr/boardgame: Heroku app to explore boardgame data), but when running the app, it shows me the Attribute Error below.

Can anyone of you guys help me with this? I tried to solve based on similar problems, but didn’t find any.

Thanks in advance!

Hi @Ash1, welcome to the Streamlit community!

Does your app work if you remove your type annotation?


Hi @randyzwitch, thank you for your reply.

I removed Tuple next to the brackets, but it threw the same error into my face. Did I understand type annotation correctly or did you mean something different?


Yes, that is what I meant.

I suspect the issue is that codebase is on such an old version of Streamlit that the code has been re-organized. In general, I wouldn’t expect someone to be writing code that tests or expects a DeltaGenerator return, and in this case, I think your version of Streamlit is too new relative to the type annotations.

0.49 is nearly 30 versions behind the current version of Streamlit, a lot has happened since then.


Hi Randy, thank you for this insight! I’m still new to data science, but from now on I’ll check the versions before I post. Thanks again, have a great day!
Regards, Ash