node-tree-sitter icon indicating copy to clipboard operation
node-tree-sitter copied to clipboard

The prebuild binaries are absent in version 0.25.0, which is a defect.

Open tobiashochguertel opened this issue 6 months ago • 7 comments

Hello Tree-Sitter Team,

You released a new version of node-tree-sitter 0.25.0 a couple of days ago, but this release is broken because it doesn't include the prebuilds binaries of tree-sitter at all or maybe only for arm64 not. I ran into the following error:

> generate-files-md --max-size 400000 src/gh-md/types/github-types.ts src/gh-md/dashboard/src/types/types.ts src/gh-md/services/template/github-template.types.ts src/gh-md/types/types.ts src/gh-md/types/commands.ts src/gh-md/services/template/template-data.types.ts


error: Cannot find module './prebuilds/darwin-arm64/tree-sitter.node' from '/Users/tobiashochgurtel/work-dev/shell-scripts/typescript/miscellaneous/node_modules/tree-sitter/index.js'

Bun v1.2.15 (macOS arm64)

Then I checked this repository and the others to understand if I have to compile something myself for the new released version and didn't find any information about new steps to use tree-sitter for Node.js / Bun.sh.

But I found this in the GitHub Build logs:

GitHub Build for v. 0.25.0

npm notice
npm notice Publishing to https://registry.npmjs.org/ with tag latest and public access
npm error code E403
npm error 403 403 Forbidden - PUT https://registry.npmjs.org/tree-sitter - You cannot publish over the previously published versions: 0.25.0.
npm error 403 In most cases, you or one of your dependencies are requesting
npm error 403 a package version that is forbidden by your security policy, or
npm error 403 on a server you do not have access to.
npm error A complete log of this run can be found in: /home/runner/.npm/_logs/2025-06-02T18_00_59_562Z-debug-0.log
Error: Process completed with exit code 1.

The Build log shows also that it has the missing files in the build:

npm notice 26.4kB index.js
npm notice 2.0kB package.json
npm notice 553.9kB prebuilds/darwin-arm64/tree-sitter.node
npm notice 540.9kB prebuilds/darwin-x64/tree-sitter.node
npm notice 670.8kB prebuilds/linux-arm64/tree-sitter.node
npm notice 686.1kB prebuilds/linux-x64/tree-sitter.node
npm notice 487.9kB prebuilds/win32-arm64/tree-sitter.node
npm notice 487.9kB prebuilds/win32-x64/tree-sitter.node
npm notice 1.0kB src/addon_data.h
npm notice 798B src/binding.cc

But the GitHub Workflow was unable to deploy the built release because there is already a release with the same version number on npmjs.com.

  1. Then I checked again if version 0.25.0 is really released or maybe unreleased on npmjs.com, but there is also version 0.25.0 as the last one listed. Tree-sitter on npmjs.com
  2. When I look there into the Files listing, I see that there is no prebuilds directory in the package what got released.
  3. I compared it with the previous version 0.22.4 on npmjs.com. I see that 0.22.4 has a prebuilds directory with content in it.

A) Can someone fix this? B) And maybe the Build pipeline?

tobiashochguertel avatar Jun 10 '25 18:06 tobiashochguertel

I think @maxbrunsfeld rushed to publish a release on npm manually instead of letting the workflow do it.

ObserverOfTime avatar Jun 11 '25 07:06 ObserverOfTime

Yeah. I think that's the case, I think the workflow failed due to needing to renew the npm token. So probably the npm token needs to renewed and updated in GitHub, and then a new version published.

segevfiner avatar Jun 15 '25 14:06 segevfiner

No I'm pretty sure the token is fine.

ObserverOfTime avatar Jun 15 '25 16:06 ObserverOfTime

If so. Then it's just a matter of bumping the version and letting the publish workflow do its thing.

segevfiner avatar Jun 15 '25 16:06 segevfiner

Any possibility of an update here? Even if just a patch bump to v0.25.1 to fix the build for us arm64 folks?

Frick avatar Aug 06 '25 14:08 Frick

bump

appleseed-iii avatar Aug 20 '25 21:08 appleseed-iii

I forked and released my own version, which fixes existing issues and works fine. I hope it helps.

https://www.npmjs.com/package/@keqingmoe/tree-sitter

KeqingMoe avatar Oct 17 '25 02:10 KeqingMoe