Hi there,
Today when I tried to embed Youtube video using st.video(). It showed the error message: TypeError : string argument without an encoding
Any idea, guys?
Hi there,
Today when I tried to embed Youtube video using st.video(). It showed the error message: TypeError : string argument without an encoding
Any idea, guys?
Hey @li_yulei and welcome to the community ,
Mind providing a sample of your code so we can help troubleshoot? Also, what version of Streamlit are you using and OS?
Hi @tc1,
Thanks for your response.
I upgraded streamlit to 0.57.3 and the error message changed
My code is as simple as:
import streamlit as st
url = 'https://youtu.be/FVsvrFAWDTM’
st.video(url)
Error message:
AttributeError: ‘EnumTypeWrapper’ object has no attribute 'NATIVE’
OS: Mac
Streamlit: 0.57.3
Thanks a lot.
Yulei
Hey @li_yulei,
Try running it like this if possible:
import streamlit as st
st.video('https://youtu.be/FVsvrFAWDTM')
This should do the trick and get it to work for you. Hope this helps and feel free to let us know if you need any additional help
@tc1 It works now! Thanks a lot, mate
Hey…its not working in my case…i am facing this issue…
AttributeError: ‘EnumTypeWrapper’ object has no attribute ‘NATIVE’
Thank you…
HI @Mohit_Sharma -
Can you confirm what operating system and version of Streamlit you are using? I ran the snippet provided by @tc1 and it worked for version 0.60.0 on Ubuntu 18.04 LTS
These cookies are necessary for the website to function and cannot be switched off. They are usually only set in response to actions made by you which amount to a request for services, such as setting your privacy preferences, logging in or filling in forms.
These cookies allow us to count visits and traffic sources so we can measure and improve the performance of our site. They help us understand how visitors move around the site and which pages are most frequently visited.
These cookies are used to record your choices and settings, maintain your preferences over time and recognize you when you return to our website. These cookies help us to personalize our content for you and remember your preferences.
These cookies may be deployed to our site by our advertising partners to build a profile of your interest and provide you with content that is relevant to you, including showing you relevant ads on other websites.