Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate allowed-message-origins to host-config endpoint #7342

Merged
merged 18 commits into from Oct 6, 2023

Conversation

LukasMasuch
Copy link
Collaborator

Describe your changes

This PR renames the _stcore/allowed-message-origins endpoint to _stcore/host-config. This is done in preparation for adding additional configurations that can be provided by the host platform to configure certain frontend aspects.

Testing Plan

  • Updated tests

Contribution License Agreement

By submitting this pull request you agree that all contributions to this project are made under the Apache 2.0 license.

Copy link
Collaborator

@willhuang1997 willhuang1997 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@stale
Copy link

stale bot commented Oct 3, 2023

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@LukasMasuch
Copy link
Collaborator Author

LukasMasuch commented Oct 6, 2023

I did a small iteration on this today. I split up HostConfig into two parts, LibConfig and AppConfig. LibConfig contains configurations used by anything in streamlit-lib and AppConfig has the configurations specific to streamlit-app. But this is only frontend internal; the _stcore/host-config endpoint still returns all settings. This split doubles down on the separation and clarifies what configurations are relevant for lib or app part.

This is also relevant for streamlit-lib only uses, since only the LibConfig will be available in this case by configuring it via LibContext. This PR doesn't contain any LibConfig options yet, that's why it is empty.

@LukasMasuch LukasMasuch merged commit 18d99b8 into develop Oct 6, 2023
50 checks passed
eric-skydio pushed a commit to eric-skydio/streamlit that referenced this pull request Dec 20, 2023
* Fix python test typing

* Migrate allowed origins to host-config endpoint

* Fixes

* Apply websocket connection changes

* Fix tests

* Remove host config setter

* Make a proper copy

* Rename to libconfig

* Split into app and lib config

* Correctly deconstruct

* Update comment

* Fix test lib

* Fix linting error
@LukasMasuch LukasMasuch deleted the refactor/migrate-to-host-config-endpoint branch January 23, 2024 00:24
zyxue pushed a commit to zyxue/streamlit that referenced this pull request Mar 22, 2024
* Fix python test typing

* Migrate allowed origins to host-config endpoint

* Fixes

* Apply websocket connection changes

* Fix tests

* Remove host config setter

* Make a proper copy

* Rename to libconfig

* Split into app and lib config

* Correctly deconstruct

* Update comment

* Fix test lib

* Fix linting error
zyxue pushed a commit to zyxue/streamlit that referenced this pull request Apr 16, 2024
* Fix python test typing

* Migrate allowed origins to host-config endpoint

* Fixes

* Apply websocket connection changes

* Fix tests

* Remove host config setter

* Make a proper copy

* Rename to libconfig

* Split into app and lib config

* Correctly deconstruct

* Update comment

* Fix test lib

* Fix linting error
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants