[BugFix][Android] Reject unsafe Lynx viewport threading - #127
Open
Huxpro wants to merge 1 commit into
Open
Conversation
Summary of change: - Reject fixed viewport and MULTI_THREADS after resolving page and global precedence. - Fail synchronously with a Java-friendly typed configuration exception before container launch or Lynx view construction. - Preserve existing behavior for safe thread strategy and viewport combinations. - Document the compatibility rule and resolution order in English and Chinese. TEST: PATH=/tmp/sparkling-ktlint-bin:$PATH scripts/lint.sh kotlin TEST: Local focused Gradle tests did not complete because the local environment/download path timed out; validation will run against the SG1 cache. Co-authored-by: TRAE CLI <noreply@bytedance.com>
This was referenced Aug 9, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
MULTI_THREADSbefore Activity launch or Lynx view constructionWhy
Android Sandbox comparison reproduced the same native
liblynx.solayout SIGSEGV through both Sparkling and a direct rawLynxViewBuilder. Setter order changed timing but was not a reliable workaround. Rejecting this one known-unsafe combination prevents a process crash until the shared Lynx SDK/core race is fixed.Stack
agent/android-failed-view-retry)Test Plan
PATH=/tmp/sparkling-ktlint-bin:$PATH scripts/lint.sh kotlinAndroid Sandbox Evidence
aries_10, Android 10/API 29, arm64-v8aOK (2 tests),INSTRUMENTATION_CODE: -1MULTI_THREADS: typedFIXED_VIEWPORT_WITH_MULTI_THREADSbefore launch;startActivitycount remained0PART_ON_LAYOUT: real 88,577-byte bundle reached first screen/load finish; measured and layout size320x480; underlying LynxView strategyPART_ON_LAYOUT3e2c12b2d025fc0853c64c936976dbfa2b591204907652ac4ebc8f95e440ffd5Expanded durable device validation
The checked-in SG1 + Lynx Sandbox matrix in #131 now validates exact commit
df875a87541d587ab8aa84a86600c0610f9e44c7with 10/10 PASS onaries_10(Android 10 / API 29). Added runtime coverage includes: the pre-load listener observing a ready bridge before template fetch; the global per-page fetcher factory; real first-screen rendering forALL_ON_UI,MOST_ON_TASM,PART_ON_LAYOUT, and safeMULTI_THREADS; and full-page fixed-viewport +MULTI_THREADSrejection before Activity launch or transfer-station save. The runner requires a clean exact HEAD and fails closed unless Sandbox release confirms the leased serial. Evidence:/tmp/sparkling-android-device-acceptance-df875a8; archive SHA-256712a3b83dbd78eabeae9afc0766b5b191cee0bff10e515967b3ae9f46c4feb98.