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

408-three-fold-approach #489

Merged
merged 2 commits into from
May 19, 2023
Merged

408-three-fold-approach #489

merged 2 commits into from
May 19, 2023

Conversation

alishaevn
Copy link
Contributor

@alishaevn alishaevn commented May 19, 2023

Story

HYRAX_ANALYTICS=true is still set in the staging and prod environments so that the client doesn't miss any tracking. therefore, all the analytics partials still try to load. although the config got set initially, once we went through the hyku account settings, each config property was set to an empty string. so when the dashboard tried to load the user graph, the config was invalid.

we need for the app to still be able to read from the env variables, (old way) while also setting some defaults in the account settings. (new way) (e.g., adding fallbacks in #reload_analytics). the values won't show up in the ui though, so the client can still set them individually. the changes in this pr will be removed in #487 so that we are only using the "per tenant" approach.

as background: this change was also necessary because of the changes made to Hyrax::Analytics::Google#valid?. the method changes are better because we should be checking for the presence of values, not just keys. however, that's what caused us to need a fallback for our new settings fields.

Refs:

Expected Behavior Before Changes

  • the dashboard wouldn't load on staging because the analytics config was invalid

Expected Behavior After Changes

  • leave the default analytics settings until the customer has updated the tenant settings in each environment

@alishaevn alishaevn requested a review from orangewolf May 19, 2023 00:48
@alishaevn alishaevn merged commit 6e3f4d2 into main May 19, 2023
@alishaevn alishaevn deleted the 408-three-fold-approach branch May 19, 2023 05:28
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.

2 participants