Skip to content

docs: sync Chinese README and update Node.js requirement to 22 - #4185

Open
MoeDawn wants to merge 4 commits into
PrismarineJS:masterfrom
MoeDawn:docs/zh-readme-fixes
Open

MoeDawn wants to merge 4 commits into
PrismarineJS:masterfrom
MoeDawn:docs/zh-readme-fixes

Conversation

@MoeDawn

@MoeDawn MoeDawn commented Oct 12, 2026

Copy link
Copy Markdown

Summary

The Chinese README had fallen behind the English source. This brings it back in
line and fixes the errors in it. Three commits:

  1. docs(zh): sync with the English README — adds the missing Microsoft auth
    paragraph, refreshes the plugin and project lists, and fixes accumulated
    mistranslations, broken commands and a stale version line
  2. docs(zh): use the English README's badges — replaces the stale badge block
  3. docs: update minimum Node.js version to 22 — docs/README.md only

Content that was missing or stale (docs/zh/README_ZH_CN.md)

  • The paragraph explaining auth: 'microsoft' (browser code login, token
    caching, profilesFolder) and its link to node-minecraft-protocol's API doc
    was absent entirely.
  • Added minecraft-mcp-server, Movement, Voyager, mindcraft and
    OpenDeliveryBot. Dropped blockfinder and scaffold, which the English
    README no longer lists.
  • statemachine, Collect Block and PVP moved to this org; the links still
    pointed at TheDudeFromCI. The Auto Eat link had the author's name misspelled.
  • username is now described the way node-minecraft-protocol does: the name to
    join as when auth is offline, otherwise a per-account identifier.
  • The viewer's port is the minecraft server port — the Chinese text called it
    the local web page port.
  • The version line now reads 26.1 and carries the <!--version--> marker.
    .github/helper/updator.js only rewrites docs/README.md, so this line is
    updated by hand and had stopped at 1.21.11.

Fixes

  • 酿造台 -> 发射器: the English says dispensers, not brewing stands.
  • npm mocha_test -> npm run mocha_test. Without run, npm invokes no script.
  • &trade; had split into & trade; and rendered as literal text.
  • 进行 1.18.1 寻路测试 -> 运行 1.18.1 的 block finder 测试. The test runs
    examples/blockfinder.js, a bot that answers find <block> by calling
    bot.findBlocks and reporting what it found nearby; it contains no
    pathfinding. The Chinese described it as a pathfinding test.
  • 数千个 -> 数百个: the English says "and hundreds more".
  • prismarine-recipe was described as a crafting table rather than recipes.
  • The first code fence was closed with four backticks, breaking the rendering.
  • 在 windows 上: -> 在 Windows 上: (capitalised, full-width colon). The
    English source still uses On windows :; this is a Chinese localisation fix
    and the English line is left untouched.

Badges

The Chinese badge block had not been kept in sync with the English one, and some
of its badges no longer work. It now matches the English block.

The ES, FR, TR and BR READMEs still carry the old block and have the same
problem. Fixing those is out of scope here.

Node.js requirement (docs/README.md and docs/zh/README_ZH_CN.md)

engines.node has been ">=22" since dbff931 (Use node 22, #3570), but both
READMEs still told readers to install 18. Both are updated so they stay in sync.

Relationship to #3885

Refs #3885

#3885 also touches docs/zh/README_ZH_CN.md. Both PRs start from the same
upstream English README and share a lot of wording; #3885 is a full
retranslation of the file, while this PR is an independent targeted pass over
it. Whichever merges first, the other will need a rebase.

A few of the fixes in this PR are not present in #3885's version of the file:
the supported-version line, the dispensers mistranslation, the two test
commands missing run, and the plugin links that moved to this org. If #3885
lands first, these would need to be carried over when resolving conflicts — I'm
happy to rebase this branch and do that. #3885 goes further than this PR in the
rest of the folder, covering docs/zh/api.md, tutorial.md, FAQ.md,
CONTRIBUTING.md and history.md.

Verification

npm run lint (standard && standard-markdown) passes locally. Heading count
(23), unique link set (94) and list lengths now match the English README.

The Chinese badge block had not been kept in sync with the English one, and
some of its badges no longer work.
The Chinese README had fallen behind the English source. Catch it up and fix
what regressed along the way.

* add the microsoft auth / token-caching paragraph and its API doc link; the
  paragraph was absent entirely
* add minecraft-mcp-server, Movement, Voyager, mindcraft and OpenDeliveryBot;
  drop blockfinder and scaffold, which the English README no longer lists
* point statemachine, Collect Block and PVP at this org (they moved from
  TheDudeFromCI) and fix the Auto Eat link, whose author was misspelled
* describe `username` as node-minecraft-protocol does: the name to join as when
  `auth` is `offline`, otherwise a per-account identifier
* say the viewer's `port` is the minecraft server port
* raise the version line to 26.1 and restore the <!--version--> marker
* 酿造台 -> 发射器; `npm mocha_test` -> `npm run mocha_test`; `&trade;` had
  split into `& trade;`; BlockFinder finds blocks, not paths; 数千个 -> 数百个
  (hundreds); prismarine-recipe is recipes, not a crafting table
* close the first code fence with three backticks, not four
* Node.js >= 22, matching engines.node; capitalise Windows and use a full-width
  colon after it
engines.node has been ">=22" since dbff931 (Use node 22, PrismarineJS#3570), but the
README still told readers to install 18.
@MoeDawn
MoeDawn force-pushed the docs/zh-readme-fixes branch from a5da4e7 to ff1a13b Compare October 30, 2026 02:50
@MoeDawn

MoeDawn commented Nov 2, 2026

Copy link
Copy Markdown
Author

I have rebased my branch onto the latest master and force-pushed the changes.

@MoeDawn MoeDawn closed this Nov 12, 2026
@MoeDawn MoeDawn reopened this Nov 12, 2026
@MoeDawn
MoeDawn marked this pull request as draft November 12, 2026 06:48
@MoeDawn
MoeDawn marked this pull request as ready for review November 12, 2026 06:49
@github-actions

github-actions Bot commented Nov 12, 2026 •

Copy link
Copy Markdown
Contributor

No tests are more than 2x slower than master's recent runs anymore.

@rom1504 rom1504 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Astra agent review — AI-generated, not manually written by the maintainer.

Reviewed ff1a13b95f0d. The Node 22 and command fixes are useful, but one newly translated statement reverses the actual viewer API contract: the viewer port is its local HTTP/socket server port, not the Minecraft server’s port. The English source has the same mistake; copying that wording into another locale would spread it. Please correct both lines while touching the source README.

Skills used: prismarine-architecture-review: checked the public option against its owning package; prismarine-review: reviewed the changed documentation and surrounding examples rather than requiring tests for prose.

Validation: Static comparison of both changed READMEs, package engines and current prismarine-viewer/lib/mineflayer.js. Viewer constructs an HTTP server and calls http.listen(port). No runtime tests needed for this documentation correction; current CI is green.

Comment thread docs/zh/README_ZH_CN.md Outdated
const { mineflayer: mineflayerViewer } = require('prismarine-viewer')
bot.once('spawn', () => {
mineflayerViewer(bot, { port: 3007, firstPerson: true }) // port 是本地网页运行的端口 ,如果 firstPerson: false,那么将会显示鸟瞰图。
mineflayerViewer(bot, { port: 3007, firstPerson: true }) // port 是 minecraft 服务器端口,如果 firstPerson 为 false,你将得到鸟瞰视角

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Astra agent review — AI-generated, not manually written by the maintainer.

[P2] This port belongs to the viewer web server. prismarine-viewer/lib/mineflayer.js creates the HTTP/socket server and calls http.listen(port); it does not change the bot’s Minecraft connection. The previous Chinese wording was correct here. Describing3007 as the Minecraft server port can make users point the viewer at25565 and collide with a local game server. Restore the web-server wording and correct the matching English comment as well.

Skills used: prismarine-architecture-review: verifies a documented public option against its actual package owner.

The port option of prismarine-viewer starts the local web server
(http.listen in prismarine-viewer/lib/mineflayer.js); it does not
change the bot Minecraft connection. Restore the correct Chinese
wording and fix the same wrong comment in the English README.

This branch has not been deployed

No deployments
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