Skip to content

Conversation

@vdonato
Copy link
Collaborator

@vdonato vdonato commented Mar 24, 2021

Currently, MetricsManager only enqueues events when we attempt to send
them before it has been initialized, so trying to send an event when
MetricsManager was initialized but the app is disconnected from the
server results in an error being thrown.

This generally doesn't happen very much in practice (you see it from
time to time when developing streamlit itself when the react dev server
reloads files, but I'm not aware of any other instances where we run into
this).

Some of the theme metrics that I want to add, however, will run into
this when trying to record that a user changed their app's theme while
the app is disconnected, so this needs to be fixed before those metrics
can be added.

Closes #2958

@vdonato vdonato requested a review from a team March 24, 2021 04:33
Currently, MetricsManager only enqueues events when we attempt to send
them before it has been initialized, so trying to send an event when
MetricsManager was initialized but the app is disconnected from the
server results in an error being thrown.

This generally doesn't happen very much in practice (you see it from
time to time when developing streamlit itself when the react dev server
reloads files, but I'm not aware of any other instances where we run into
this).

Some of the theme metrics that I want to add, however, will run into
this when trying to record that a user changed their app's theme while
the app is disconnected, so this needs to be fixed before those metrics
can be added.

Closes streamlit#2958
@vdonato vdonato merged commit 54b6c34 into streamlit:develop Mar 29, 2021
vdonato added a commit to vdonato/streamlit that referenced this pull request Mar 29, 2021
Note: This builds off streamlit#3011, so that PR should be reviewed first.

With a few small issues with MetricsManager cleaned up, we can now
collect all the theme-related data points we wanted to.
@vdonato vdonato deleted the metrics-manager-disconnect-handling branch March 29, 2021 23:04
vdonato added a commit that referenced this pull request Mar 29, 2021
Note: This builds off #3011, so that PR should be reviewed first.

With a few small issues with MetricsManager cleaned up, we can now
collect all the theme-related data points we wanted to.
tconkling added a commit that referenced this pull request Mar 30, 2021
* develop:
  Set baseUrl to .
  Speed up CircleCI more (#3025)
  Add events to keep track of theme changes and other theme stats (#3012)
  Have MetricsManager enqueue events when disconnected (#3011)
  Fix for query param issue with base url (#2894)
  Add fuzzy search to selectbox (#2933)
  Informative repr methods for our python classes (#3027)
  ComponentInstance: handle iframe changes (#3015)
tconkling added a commit to tconkling/streamlit that referenced this pull request Mar 30, 2021
* st_form:
  Set baseUrl to .
  Speed up CircleCI more (streamlit#3025)
  Add events to keep track of theme changes and other theme stats (streamlit#3012)
  Have MetricsManager enqueue events when disconnected (streamlit#3011)
  Fix for query param issue with base url (streamlit#2894)
  Add fuzzy search to selectbox (streamlit#2933)
  Informative repr methods for our python classes (streamlit#3027)
  ComponentInstance: handle iframe changes (streamlit#3015)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Have MetricsManager enqueue events while app is disconnected

1 participant