Skip to content

fix(benchx_cli): resolve upstream conflict#2221

Merged
colinaaa merged 1 commit intolynx-family:mainfrom
hzy:p/hzy/benchx_cli_maintenance
Feb 13, 2026
Merged

fix(benchx_cli): resolve upstream conflict#2221
colinaaa merged 1 commit intolynx-family:mainfrom
hzy:p/hzy/benchx_cli_maintenance

Conversation

@hzy
Copy link
Copy Markdown
Collaborator

@hzy hzy commented Feb 10, 2026

Update commit references and improve build script for lynx

Summary by CodeRabbit

  • Chores
    • Updated CI runner image to a different Ubuntu runner variant.
    • Streamlined build orchestration and environment setup, including repo prep, venv handling, and uniform build output handling.
    • Neutralized an Android SDK manager dependency in build configuration (kept as commented reference).
    • Added a changeset metadata file (no functional or behavioral changes).

Checklist

  • Tests updated (or not required).
  • Documentation updated (or not required).
  • Changeset added, and when a BREAKING CHANGE occurs, it needs to be clearly marked (or not required).

Copilot AI review requested due to automatic review settings February 10, 2026 15:50
@changeset-bot
Copy link
Copy Markdown

changeset-bot bot commented Feb 10, 2026

🦋 Changeset detected

Latest commit: 56ffe5d

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 0 packages

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the benchx_cli CI build script to resolve an upstream conflict by moving to new upstream commit references and adjusting how the Lynx source is fetched and built.

Changes:

  • Updated pinned upstream commit SHAs used to fetch/cherry-pick Lynx changes.
  • Replaced git clone with an explicit git init + git fetch flow for preparing the Lynx repo.
  • Adjusted GN args generation (including a macOS-specific use_flutter_cxx=false) and removed the Android SDK manager patch application.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
packages/lynx/benchx_cli/scripts/build.mjs Updates commit pins and modifies repo preparation + build steps for Lynx in CI.
packages/lynx/benchx_cli/patches/android_sdk_manager.diff Removes an obsolete patch that was previously applied during the build.

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

Comment thread packages/lynx/benchx_cli/scripts/build.mjs Outdated
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Feb 10, 2026

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

Adds a changeset file, comments out the Android SDK manager DEPS entry, and updates the benchx_cli build script: commit targets, repo checkout flow, virtualenv/pip steps, habitat sync adjustments, GN gen args, and artifact copy logic.

Changes

Cohort / File(s) Summary
Changelog
\.changeset/vast-parents-swim.md
Added a new changeset file containing YAML separators.
DEPS patch
packages/lynx/benchx_cli/patches/android_sdk_manager.diff
Disabled the buildtools/android_sdk_manager DEPS entry by replacing it with a commented block.
Build automation
packages/lynx/benchx_cli/scripts/build.mjs
Updated COMMIT/PICK_COMMIT hashes; changed repo prep from git clone to git init + remote/fetch/cherry-pick; added Python venv and pip install steps; adjusted habitat sync and gn gen args (macOS conditional); simplified artifact copy and commit recording.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

Suggested reviewers

  • colinaaa

Poem

🐇 I hopped through lines and left a tiny trace,
Commented out a tool and tuned the checkout pace.
I spun a cozy venv, pinned commits with care,
Copied artifacts neatly, then twitched my whiskers in the air.

🚥 Pre-merge checks | ✅ 1 | ❌ 2
❌ Failed checks (2 warnings)
Check name Status Explanation Resolution
Title check ⚠️ Warning The title mentions resolving an upstream conflict but the changes show updates to commit references, build scripts, CI runner images, and a changeset file—no evidence of actual conflict resolution. Revise the title to accurately reflect the main changes, such as 'chore(benchx_cli): update build scripts and commit references' or similar.
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (1 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

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 and usage tips.

@codecov
Copy link
Copy Markdown

codecov bot commented Feb 10, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ All tests successful. No failed tests found.

📢 Thoughts on this report? Let us know!

@codspeed-hq
Copy link
Copy Markdown

codspeed-hq bot commented Feb 10, 2026

Merging this PR will degrade performance by 32.31%

⚡ 2 improved benchmarks
❌ 32 regressed benchmarks
✅ 29 untouched benchmarks
⏩ 3 skipped benchmarks1

⚠️ Please fix the performance issues or acknowledge them on CodSpeed.

Performance Changes

Benchmark BASE HEAD Efficiency
faster fib(20) 46.6 µs 50.1 µs -7%
003-hello-list__main-thread-componentAtIndex__reuse 3.1 ms 2.4 ms +26.62%
003-hello-list__main-thread-renderMainThread 14.7 ms 16.4 ms -10.33%
003-hello-list__main-thread-processData 22.3 µs 24 µs -7.25%
more faster fib(20) 16.2 µs 18.9 µs -14.45%
006-static-raw-text__main-thread-renderOpcodes 3.2 ms 3.5 ms -7.73%
004-various-update-setAttribute__BatchedValues 316.1 µs 336.1 µs -5.96%
003-hello-list__main-thread-renderOpcodes 2.2 ms 2.5 ms -9.02%
slower fib(20) 5.3 ms 5.7 ms -7.01%
006-static-raw-text__main-thread-serializeRoot 910.8 µs 985.2 µs -7.55%
004-various-update__main-thread-setAttribute__MT_Event 96.1 µs 90 µs +6.75%
004-various-update/background.js_LoadScript 384.7 µs 421 µs -8.64%
003-hello-list__main-thread-serializeRoot 3.7 ms 4.1 ms -9.89%
001-fib/background.js_LoadScript 565.3 µs 609.3 µs -7.23%
005-load-script/background.js_LoadScript 1.2 ms 1.3 ms -7.77%
002-hello-reactLynx-destroyBackground 615.7 µs 909.6 µs -32.31%
002-hello-reactLynx-renderBackground 2.6 ms 2.8 ms -7.24%
005-load-script/main-thread.js_LoadScript 1.1 ms 1.2 ms -9.47%
006-static-raw-text-renderBackground 2.9 ms 3.2 ms -8.32%
002-hello-reactLynx__main-thread-processData 21.6 µs 23 µs -5.97%
... ... ... ... ...

ℹ️ Only the first 20 benchmarks are displayed. Go to the app to view all benchmarks.


Comparing hzy:p/hzy/benchx_cli_maintenance (56ffe5d) with main (63a1cdb)2

Open in CodSpeed

Footnotes

  1. 3 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

  2. No successful run was found on main (b73e766) during the generation of this report, so 63a1cdb was used instead as the comparison base. There might be some changes unrelated to this pull request in this report.

@relativeci
Copy link
Copy Markdown

relativeci bot commented Feb 10, 2026

Web Explorer

#7673 Bundle Size — 383.74KiB (0%).

56ffe5d(current) vs 87682f6 main#7667(baseline)

Bundle metrics  Change 1 change
                 Current
#7673
     Baseline
#7667
No change  Initial JS 154.88KiB 154.88KiB
No change  Initial CSS 35.06KiB 35.06KiB
No change  Cache Invalidation 0% 0%
No change  Chunks 8 8
No change  Assets 8 8
Change  Modules 238(+0.42%) 237
No change  Duplicate Modules 16 16
No change  Duplicate Code 2.99% 2.99%
No change  Packages 4 4
No change  Duplicate Packages 0 0
Bundle size by type  no changes
                 Current
#7673
     Baseline
#7667
No change  JS 252.83KiB 252.83KiB
No change  Other 95.85KiB 95.85KiB
No change  CSS 35.06KiB 35.06KiB

Bundle analysis reportBranch hzy:p/hzy/benchx_cli_maintenanceProject dashboard


Generated by RelativeCIDocumentationReport issue

@hzy hzy force-pushed the p/hzy/benchx_cli_maintenance branch 2 times, most recently from cc9d315 to 29c19be Compare February 10, 2026 17:15
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@packages/lynx/benchx_cli/scripts/build.mjs`:
- Around line 91-100: The script currently adds a hardcoded personal fork via
the git command "git remote add hzy https://github.com/hzy/lynx" and then
fetches and cherry-picks ${PICK_COMMIT}, which is fragile; update the script to
stop referencing the personal URL directly by either (A) pushing the patch
commit into an org-owned repository and replace "https://github.com/hzy/lynx"
with the org repo URL, or (B) make the remote configurable by introducing an
environment variable (e.g., PICK_REMOTE_URL and PICK_REMOTE_NAME) and use those
in the "git remote add" and "git fetch" steps so the script uses a stable org
repo by default while allowing overrides; ensure references to the remote name
"hzy" and usage of ${PICK_COMMIT} are updated to use the new variable names.

Comment thread packages/lynx/benchx_cli/scripts/build.mjs
@hzy hzy force-pushed the p/hzy/benchx_cli_maintenance branch 2 times, most recently from 078e395 to 30b6dd4 Compare February 11, 2026 14:25
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
packages/lynx/benchx_cli/scripts/build.mjs (1)

103-111: ⚠️ Potential issue | 🟡 Minor

Document uv as a required tool and add installation or error handling.

The build script uses uv (lines 103-111) but there's no documentation of this requirement in CONTRIBUTING.md or elsewhere. If uv is not pre-installed in CI runners, the build fails with a confusing "command not found" error. Either:

  • Add uv to the documented requirements in CONTRIBUTING.md and ensure CI installs it, or
  • Add a guard with a clear error message explaining that uv must be installed
🧹 Nitpick comments (2)
packages/lynx/benchx_cli/scripts/build.mjs (2)

118-125: macOS-only use_flutter_cxx=false — consider adding a comment explaining why.

The conditional GN arg use_flutter_cxx=false is only added on macOS. A brief inline comment explaining the reason (e.g., a macOS-specific linker issue, incompatible system library, etc.) would help future maintainers understand this platform divergence.

💡 Suggested comment
 gn gen --args=${
   process.platform === 'darwin'
-    ? `enable_unittests=true enable_trace="perfetto" jsengine_type="quickjs" enable_frozen_mode=true use_flutter_cxx=false`
+    // use_flutter_cxx=false is required on macOS to avoid <reason>
+    ? `enable_unittests=true enable_trace="perfetto" jsengine_type="quickjs" enable_frozen_mode=true use_flutter_cxx=false`
     : `enable_unittests=true enable_trace="perfetto" jsengine_type="quickjs" enable_frozen_mode=true`
 } out/Default

118-122: Duplicated GN args string — extract to reduce maintenance burden.

The two GN arg strings are identical except for the trailing use_flutter_cxx=false on macOS. If more flags are added later, both branches need updating. Consider extracting the common base:

♻️ Suggested refactor
const BASE_GN_ARGS = `enable_unittests=true enable_trace="perfetto" jsengine_type="quickjs" enable_frozen_mode=true`;
const GN_ARGS = process.platform === 'darwin'
  ? `${BASE_GN_ARGS} use_flutter_cxx=false`
  : BASE_GN_ARGS;

Then use ${GN_ARGS} in the template literal.

colinaaa
colinaaa previously approved these changes Feb 11, 2026
@hzy hzy force-pushed the p/hzy/benchx_cli_maintenance branch 3 times, most recently from cfcc97c to ff884f3 Compare February 12, 2026 13:36
Update commit references and improve build script for lynx
@hzy hzy force-pushed the p/hzy/benchx_cli_maintenance branch from ff884f3 to 56ffe5d Compare February 12, 2026 13:40
@colinaaa colinaaa merged commit b89b3e3 into lynx-family:main Feb 13, 2026
138 of 143 checks passed
hzy added a commit to hzy/lynx-stack that referenced this pull request Feb 13, 2026
@coderabbitai coderabbitai bot mentioned this pull request Mar 2, 2026
3 tasks
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.

3 participants