Hello, I struggle with filling text inputs with my password manager (Dashlane, but I don’t think it matters)
When the fields are filled this way and I get what’s inside the text input I get an empty string. My guess is that usually typing something in a field triggers a callback and using an autofill tool does not trigger it.
Steps to reproduce
name = st.text_input("First Name")
if __name__ == '__main__':
Obviously to reproduce the example you need a password manager. I use Dashlane which is free and automatically recognize this field as asking for my first name.
We would expect for the app to get what’s intisde those fields. Although I understand we may not be able to constantly check what’s inside all the fields all the time, I would need a way to trigger a check when pressing the submit button.
I did not find anyone talking about this issue or any solution.
- Streamlit version: 1.26.0
- Python version: 3.10.12
- OS version: Linux
Actually the code can run as is and I don’t understand how it is related to a password manager.
When you type in a textbox, the new value isn’t available to the application until the you press Enter or change the focus to another widget. It doesn’t matter if you type with your fingers or you paste from the clipboard or you use some magic to fill the widget.
Yes, if you run the code as is you can type somthing in the input field, press the submit button and it will show your name.
But if instead of putting it by hand a password manager puts it in for you it doesnt’t work anymore (which defeat the purpose of the autofill), see 2nd screenshot, the success output is empty even though the field is not. (I pressed the submit button after my password manager put my name in the field)