From the ipywidgets guide for users I copied and run
import ipywidgets as widgets
widgets.FileUpload(
accept='', # Accepted file extension e.g. '.txt', '.pdf', 'image/*', 'image/*,.pdf'
multiple=False # True to accept multiple files upload else False
)
But I get the error
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
<ipython-input-4-db1cf4369e31> in <module>
1 import ipywidgets as widgets
----> 2 widgets.FileUpload(
3 accept='', # Accepted file extension e.g. '.txt', '.pdf', 'image/*', 'image/*,.pdf'
4 multiple=False # True to accept multiple files upload else False
5 )
AttributeError: module 'ipywidgets' has no attribute 'FileUpload'
What might be the reason for this error? Any pointers would be great.
I'm running jupyter notebook with Python 3 kernel.