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

Fix version upgrade toast refresh issue #179

Merged
merged 2 commits into from
Jan 28, 2025

Conversation

brendan-kellam
Copy link
Contributor

This PR fixes a issue where the version upgrade toast only appeared after force-refreshing the browser, even when a new version was available.

Previously, the client was getting the current Sourcebot version via a client-side environment variable that is baked into the JS bundles at build time. There is some weirdness with how those bundles are refreshed on the browser (I think), which is why a hard refresh is required.

The fix is to add a /api/version api route that will fetch the Sourcebot version from a server-side environment variable.

@brendan-kellam brendan-kellam force-pushed the bkellam/fix_version_toast branch from db4ca65 to b2ea4e6 Compare January 28, 2025 16:27
@brendan-kellam brendan-kellam merged commit 27dde3a into main Jan 28, 2025
3 checks passed
@brendan-kellam brendan-kellam deleted the bkellam/fix_version_toast branch January 28, 2025 17:04
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