Skip to content

Bump radiance for non-blocking fronted-config startup#8920

Merged
myleshorton merged 1 commit into
mainfrom
fisk/bump-radiance-config-persist
Jul 22, 2026
Merged

Bump radiance for non-blocking fronted-config startup#8920
myleshorton merged 1 commit into
mainfrom
fisk/bump-radiance-config-persist

Conversation

@myleshorton

@myleshorton myleshorton commented Jul 22, 2026

Copy link
Copy Markdown
Contributor

Bumps radianceb72b27d, carrying the fronted-config init fix into the client. domainfront (→ 2862f7a) moves with it as an indirect dep.

Why

This is the last hop of the chain domainfront#16radiance#573here.

radiance previously fetched the fronting config (fronted.yaml.gz) from raw.githubusercontent.com synchronously on the init critical path with a 30s timeout. That host is blocked in China, so every cold start there burned the full 30s before falling back to cached/embedded config — stalling radiance init, which (with the Android startup race, symptom-fixed in #8915) left Pro users shown as logged-out.

After this bump, domainfront owns the config lifecycle: it fetches configURL off the critical path, persists each fetched config, and bootstraps from the persisted copy on the next start (preferring it over the embedded seed). Startup does no blocking network I/O.

This PR

go.mod / go.sum only — no lantern code changes. Ran go mod tidy; go build ./... passes.

Follow-up (not blocking)

This makes startup resilient and preserves the last-good config across restarts, but doesn't make the fetch succeed in China (raw.githubusercontent.com blocked; jsDelivr bans the getlantern org). getlantern/engineering#3721 tracks a China-reachable config mirror.

Summary by CodeRabbit

  • Chores
    • Updated internal libraries to newer versions.
    • No user-facing features or behavior changes.

Bumps radiance to b72b27d, carrying the fronted-config init fix into the
client. domainfront (=> 2862f7a) moves with it as an indirect dep.

radiance no longer fetches the fronting config (fronted.yaml.gz) from
raw.githubusercontent.com synchronously on the init critical path — a fetch
that stalled startup for 30s per cold start where GitHub is blocked (China),
contributing to the Android "Pro users shown as logged-out" cluster
(getlantern/engineering#3716, symptom fixed in #8915). domainfront now owns
the config lifecycle (fetch off the critical path → persist → bootstrap from
the persisted copy), so startup does no blocking network I/O.

go.mod / go.sum only; ran `go mod tidy`. `go build ./...` passes.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings July 22, 2026 16:13
@coderabbitai

coderabbitai Bot commented Jul 22, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 91eb0a5c-5265-4b04-9496-ebb8d3f56b13

📥 Commits

Reviewing files that changed from the base of the PR and between ccd1667 and 01a0d5e.

⛔ Files ignored due to path filters (1)
  • go.sum is excluded by !**/*.sum
📒 Files selected for processing (1)
  • go.mod

📝 Walkthrough

Walkthrough

Updates the required versions of github.com/getlantern/radiance and github.com/getlantern/domainfront in go.mod. No other module directives or exported entities are changed.

Changes

Go module dependency updates

Layer / File(s) Summary
Update module requirements
go.mod
The required versions of github.com/getlantern/radiance and github.com/getlantern/domainfront are updated.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Possibly related PRs

Suggested reviewers: copilot, jigar-f, garmr-ulfr

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title matches the main change: upgrading radiance to enable non-blocking fronted-config startup.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fisk/bump-radiance-config-persist

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 Checkov (3.3.8)
go.mod

Traceback (most recent call last):
File "/usr/local/bin/checkov", line 2, in
from checkov.main import Checkov
ModuleNotFoundError: No module named 'checkov'


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR updates Go module dependencies to pull in the radiance change that moves fronted.yaml.gz fetching off the init critical path (via updated domainfront), avoiding blocking network I/O during startup.

Changes:

  • Bump github.com/getlantern/radiance to b72b27d.
  • Update indirect github.com/getlantern/domainfront to 2862f7a (via radiance).
  • Refresh go.sum entries accordingly.

Reviewed changes

Copilot reviewed 1 out of 2 changed files in this pull request and generated no comments.

File Description
go.mod Updates required/indirect module versions for radiance/domainfront.
go.sum Updates checksums to match the new module versions.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@myleshorton
myleshorton merged commit a299529 into main Jul 22, 2026
11 checks passed
@myleshorton
myleshorton deleted the fisk/bump-radiance-config-persist branch July 22, 2026 16:18
jigar-f added a commit that referenced this pull request Jul 23, 2026
* Fix Android user data startup race (#8915)

* Fix Android user data startup race

* code review updates

* code review updates

* Bump radiance for non-blocking fronted-config startup (#8920)

Bumps radiance to b72b27d, carrying the fronted-config init fix into the
client. domainfront (=> 2862f7a) moves with it as an indirect dep.

radiance no longer fetches the fronting config (fronted.yaml.gz) from
raw.githubusercontent.com synchronously on the init critical path — a fetch
that stalled startup for 30s per cold start where GitHub is blocked (China),
contributing to the Android "Pro users shown as logged-out" cluster
(getlantern/engineering#3716, symptom fixed in #8915). domainfront now owns
the config lifecycle (fetch off the critical path → persist → bootstrap from
the persisted copy), so startup does no blocking network I/O.

go.mod / go.sum only; ran `go mod tidy`. `go build ./...` passes.

Co-authored-by: Adam Fisk <a@lantern.io>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>

* Provide a writable WebView2 user-data folder on Windows (#8921)

* Provide webview path for Windows.

* go mod tidy: drop stray go-arg/go-scalar from go.sum

These entries were added to go.sum with no corresponding go.mod require and
nothing imports them, so go mod tidy removes them. Orphaned go.sum entries
can cause Go tooling (notably gomobile) to resolve transitive deps to older
hashed versions, so keep go.sum consistent with go.mod.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* windows/webview: bail on unexpanded path or failed folder creation

Address review on EnsureWebView2UserDataFolder:
- If %LOCALAPPDATA% (or any referenced var) is undefined, ExpandEnvironmentStringsW
  leaves it literal in the output; bail rather than create a garbage relative
  folder and set WEBVIEW2_USER_DATA_FOLDER to an unusable value.
- Only set WEBVIEW2_USER_DATA_FOLDER after confirming the target exists as a
  directory (via GetFileAttributesW); if CreateDirectoryW failed, leave WebView2
  to its default instead of pointing it at a nonexistent folder.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* windows/webview: narrow unexpanded-path guard to leading '%'

'%' is legal elsewhere in a Windows folder name (e.g. a username), so bailing
on any '%' could reject a valid expanded path. An undefined %LOCALAPPDATA%
leaves the template literal, so the result starts with '%' — check only the
leading char.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* windows/webview: treat empty WEBVIEW2_USER_DATA_FOLDER as unset

The null-buffer size probe returns >0 for a set-but-empty variable, so an
empty override would be respected and leave WebView2 with an unusable folder.
Read into a buffer instead: GetEnvironmentVariableW returns 0 when the var is
unset or empty, so we only bail on a real non-empty override.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

---------

Co-authored-by: jigar-f <jigar@getlantern.org>
Co-authored-by: Adam Fisk <a@lantern.io>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>

* Bump radiance for multi-URL config racing (#8924)

Bumps radiance to 838849783d37 (kindling + domainfront move with it), carrying
the variadic WithConfigURL / multi-URL config racing capability
(getlantern/domainfront#17) into the client. No behavior change yet: the client
still fetches from the single GitHub config URL; the China-reachable mirror URL
will be added to the raced set once it's publishing (getlantern/engineering#3721).

go.mod / go.sum only; ran go mod tidy; go build ./... passes.

Co-authored-by: Adam Fisk <a@lantern.io>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>

* Fix referral reward UI edge cases

* code review changes

---------

Co-authored-by: Myles Horton <afisk@getlantern.org>
Co-authored-by: Adam Fisk <a@lantern.io>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: jigar-f <jigar@getlantern.org>
jigar-f added a commit that referenced this pull request Jul 23, 2026
* Referral UI updates

* Referral notification dialogue

* code review updates

* update radiance

* point back to radiance

* update radiance

* More UI change

* Fix referral reward UI edge cases (#8925)

* Fix Android user data startup race (#8915)

* Fix Android user data startup race

* code review updates

* code review updates

* Bump radiance for non-blocking fronted-config startup (#8920)

Bumps radiance to b72b27d, carrying the fronted-config init fix into the
client. domainfront (=> 2862f7a) moves with it as an indirect dep.

radiance no longer fetches the fronting config (fronted.yaml.gz) from
raw.githubusercontent.com synchronously on the init critical path — a fetch
that stalled startup for 30s per cold start where GitHub is blocked (China),
contributing to the Android "Pro users shown as logged-out" cluster
(getlantern/engineering#3716, symptom fixed in #8915). domainfront now owns
the config lifecycle (fetch off the critical path → persist → bootstrap from
the persisted copy), so startup does no blocking network I/O.

go.mod / go.sum only; ran `go mod tidy`. `go build ./...` passes.

Co-authored-by: Adam Fisk <a@lantern.io>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>

* Provide a writable WebView2 user-data folder on Windows (#8921)

* Provide webview path for Windows.

* go mod tidy: drop stray go-arg/go-scalar from go.sum

These entries were added to go.sum with no corresponding go.mod require and
nothing imports them, so go mod tidy removes them. Orphaned go.sum entries
can cause Go tooling (notably gomobile) to resolve transitive deps to older
hashed versions, so keep go.sum consistent with go.mod.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* windows/webview: bail on unexpanded path or failed folder creation

Address review on EnsureWebView2UserDataFolder:
- If %LOCALAPPDATA% (or any referenced var) is undefined, ExpandEnvironmentStringsW
  leaves it literal in the output; bail rather than create a garbage relative
  folder and set WEBVIEW2_USER_DATA_FOLDER to an unusable value.
- Only set WEBVIEW2_USER_DATA_FOLDER after confirming the target exists as a
  directory (via GetFileAttributesW); if CreateDirectoryW failed, leave WebView2
  to its default instead of pointing it at a nonexistent folder.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* windows/webview: narrow unexpanded-path guard to leading '%'

'%' is legal elsewhere in a Windows folder name (e.g. a username), so bailing
on any '%' could reject a valid expanded path. An undefined %LOCALAPPDATA%
leaves the template literal, so the result starts with '%' — check only the
leading char.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* windows/webview: treat empty WEBVIEW2_USER_DATA_FOLDER as unset

The null-buffer size probe returns >0 for a set-but-empty variable, so an
empty override would be respected and leave WebView2 with an unusable folder.
Read into a buffer instead: GetEnvironmentVariableW returns 0 when the var is
unset or empty, so we only bail on a real non-empty override.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

---------

Co-authored-by: jigar-f <jigar@getlantern.org>
Co-authored-by: Adam Fisk <a@lantern.io>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>

* Bump radiance for multi-URL config racing (#8924)

Bumps radiance to 838849783d37 (kindling + domainfront move with it), carrying
the variadic WithConfigURL / multi-URL config racing capability
(getlantern/domainfront#17) into the client. No behavior change yet: the client
still fetches from the single GitHub config URL; the China-reachable mirror URL
will be added to the raced set once it's publishing (getlantern/engineering#3721).

go.mod / go.sum only; ran go mod tidy; go build ./... passes.

Co-authored-by: Adam Fisk <a@lantern.io>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>

* Fix referral reward UI edge cases

* code review changes

---------

Co-authored-by: Myles Horton <afisk@getlantern.org>
Co-authored-by: Adam Fisk <a@lantern.io>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: jigar-f <jigar@getlantern.org>

* code review updates

* Update referral_reward_dialog.dart

---------

Co-authored-by: atavism <atavism@users.noreply.github.com>
Co-authored-by: Myles Horton <afisk@getlantern.org>
Co-authored-by: Adam Fisk <a@lantern.io>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
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