NathanChen198 / streamlit-rsa-auth-ui

Encryption on Authenticate widget data from client to server.
MIT License
4 stars 1 forks source link

Broken in streamlit-1.34 #1

Open kaizen63 opened 6 months ago

kaizen63 commented 6 months ago

Him not sure if this is a streamlit issue or an issue in streamlit-rsa-auth-ui. Since streamlit 1.34 this module is broken.

Sampe code:

from streamlit_rsa_auth_ui import Encryptor

encryptor = Encryptor.generateNew(2048)
encryptor.save("./.rsa", "authkey")

Stack trace: Traceback (most recent call last): File "D:\DevOps\cloud_coe\sre-niq-app-metadata-ui\app\generateKeys.py", line 1, in from streamlit_rsa_auth_ui import Encryptor File "C:\Users\poitschkka01\AppData\Local\pypoetry\Cache\virtualenvs\sre-niq-app-metadata-ui-KVFfTU9t-py3.11\Lib\site-packages\streamlit_rsa_auth_ui__init__.py", line 11, in from .form import Object, authUI File "C:\Users\poitschkka01\AppData\Local\pypoetry\Cache\virtualenvs\sre-niq-app-metadata-ui-KVFfTU9t-py3.11\Lib\site-packages\streamlit_rsa_auth_ui\form.py", line 21, in _componentFunc = components.declare_component("rsa_auth_ui", path=build_dir) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\poitschkka01\AppData\Local\pypoetry\Cache\virtualenvs\sre-niq-app-metadata-ui-KVFfTU9t-py3.11\Lib\site-packages\streamlit\components\v1\component_registry.py", line 87, in declare_component get_instance().component_registry.register_component(component) ^^^^^^^^^^^^^^ File "C:\Users\poitschkka01\AppData\Local\pypoetry\Cache\virtualenvs\sre-niq-app-metadata-ui-KVFfTU9t-py3.11\Lib\site-packages\streamlit\runtime__init__.py", line 28, in get_instance return Runtime.instance() ^^^^^^^^^^^^^^^^^^ File "C:\Users\poitschkka01\AppData\Local\pypoetry\Cache\virtualenvs\sre-niq-app-metadata-ui-KVFfTU9t-py3.11\Lib\site-packages\streamlit\runtime\runtime.py", line 163, in instance raise RuntimeError("Runtime hasn't been created!") RuntimeError: Runtime hasn't been created!

kaizen63 commented 6 months ago

Looks like this is a streamlit issue: https://github.com/streamlit/streamlit/issues/8606