Skip to content

build(deps): 升级 loader 至 v0.5.3,交付 BSD mmap 修复 - #1006

Merged
liuq19 merged 1 commit into
bytedance:mainfrom
liuq19:fix/update-loader-v0.5.3
Oct 26, 2026
Merged

liuq19 merged 1 commit into
bytedance:mainfrom
liuq19:fix/update-loader-v0.5.3

Conversation

@liuq19

@liuq19 liuq19 commented Oct 21, 2026

Copy link
Copy Markdown
Collaborator

What type of PR is this?

build

Check the PR title.

  • This PR title match the format: <type>(optional scope): <description>
  • The description of this PR title is user-oriented and clear enough for others to understand.

(Optional) More detailed description for this PR(en: English/zh: Chinese).

背景

#902 已将 BSD 匿名 mmap 的 fd 从 0 修正为 -1,并随 loader/v0.5.3 发布。主模块仍依赖 loader v0.5.2,因此通过 Go Modules 使用 Sonic 的用户尚未获取到该修复。

改动方案与影响范围

将主模块 loader 依赖升级到 v0.5.3,同步模块校验和。本次仅修改 go.mod 和 go.sum;loader 的版本差异只有 mmap fd 修复及格式调整,public API 和 Go 版本要求保持不变。

测试与验证

本机环境为 Linux/amd64,以下 11 组检查全部通过:

  • Go 1.27.0:GOWORK=off go test -race -count=1 ./...,默认和 OptDec/FastMap/VM 两种模式。
  • Go 1.24.13:GOWORK=off go test -count=1 ./...,默认和 OptDec/FastMap/VM 两种模式。
  • Go 1.27.0:go test -race -count=1 ./issue_test ./generic_test,默认和 OptDec/FastMap/VM 两种模式。
  • Go 1.27.0:go test -count=1 ./compatibility/,覆盖默认/OptDec 与 jsonv2/nojsonv2 的四种组合;nojsonv2 下额外执行 issue suite。
  • Go 1.27.0:bash ./scripts/test_race.sh,确认预期的 race 仍能被检测到。

回归子模块使用不包含 ./loader 的临时 workspace;主模块测试使用 GOWORK=off。两种设置均通过 go list -m 确认实际加载发布版 loader v0.5.3,避免本地 loader 覆盖依赖升级的验证。本次未在 BSD 主机执行运行测试。

git diff --check 和分支命名检查通过。

(Optional) Which issue(s) this PR fixes:

Related to #902 and #962.

Copilot AI balanced review requested due to automatic review settings October 21, 2026 06:06
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-21T06:10:41.761675Z 58a4330 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@codecov-commenter

codecov-commenter commented Oct 21, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 53.44%. Comparing base (59be92f) to head (58a4330).
⚠️ Report is 98 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1006      +/-   ##
==========================================
+ Coverage   51.86%   53.44%   +1.57%     
==========================================
  Files         127      171      +44     
  Lines       10893    14171    +3278     
==========================================
+ Hits         5650     7574    +1924     
- Misses       4920     6502    +1582     
+ Partials      323       95     -228     
Flag Coverage Δ
arm 45.51% <ø> (?)
macos-15 47.18% <ø> (?)
ubuntu-24.04-arm 45.50% <ø> (?)
ubuntu-latest 52.19% <ø> (?)
x86 52.19% <ø> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

🟢 Approval recommended

The dependency and checksum changes are consistent with the intended fix, with no identified blocking issues.

No open issues 🎉

What changed in this PR

Updates Sonic’s loader dependency to deliver the BSD anonymous-memory mapping fix to Go Modules users.

Changes:

  • Upgrades loader from v0.5.2 to v0.5.3.
  • Synchronizes the dependency checksums.
File Description
go.sum Updates checksums for loader v0.5.3.
go.mod Requires loader v0.5.3 with the BSD fix.

Review effort: Balanced

@wdp2020 wdp2020 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM

@liuq19
liuq19 merged commit 4640e45 into bytedance:main Oct 26, 2026
53 checks passed
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.

4 participants