Skip to content

fix(zed): pin language server download to engine release tag#3847

Open
hellovai wants to merge 1 commit into
canaryfrom
hellovai/fix-zed
Open

fix(zed): pin language server download to engine release tag#3847
hellovai wants to merge 1 commit into
canaryfrom
hellovai/fix-zed

Conversation

@hellovai

@hellovai hellovai commented Jun 25, 2026

Copy link
Copy Markdown
Contributor

Problem

The Zed extension fails to start the BAML language server with:

no asset found matching "baml-cli-baml-language-0.12.2-nightly.20260625.d-aarch64-apple-darwin.tar.gz"

The extension resolved the baml-cli binary via latest_github_release, which returns the newest release across the whole repo. But the repo publishes two independent release lines:

Release line Tag Asset naming
Engine / baml-cli 0.223.0 baml-cli-0.223.0-<target>.tar.gz ✅ (what the extension wants)
baml-language-* nightlies baml-language-0.12.2-nightly.20260625.d baml-language-…-<target>.tar.gz

The nightly line currently holds GitHub's "latest" pointer, so release.version became the nightly tag and the baml-cli-{version}-{target} template produced an asset name that doesn't exist.

Fix

Pin the lookup to the engine release tag — the extension's own CARGO_PKG_VERSION (kept in sync with extension.toml via tools/versions/zed.cfg) — using github_release_by_tag_name instead of latest_github_release. The extension version and the language-server binary it downloads now stay locked together, and the nightly line is ignored entirely.

Also corrects a stale Cargo.lock version (0.218.00.223.0).

Verification

cargo check passes clean. With the extension at 0.223.0, the asset resolves to baml-cli-0.223.0-aarch64-apple-darwin.tar.gz, which exists on the engine release.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Bug Fixes
    • Language-server downloads now use a fixed release version instead of always following the latest GitHub release.
    • This helps keep the installed engine aligned with the app version, reducing mismatches and unexpected updates.

The Zed extension resolved the baml-cli language server via
`latest_github_release`, which returns the newest release across the
whole repo. The repo publishes two independent release lines: the
engine/`baml-cli` line (tagged `0.223.0`, assets `baml-cli-<ver>-<target>.tar.gz`)
and a separate `baml-language-*` nightly line that currently holds
GitHub's "latest" pointer.

As a result `release.version` became the nightly tag
`baml-language-0.12.2-nightly.20260625.d`, and the
`baml-cli-{version}-{target}` template produced an asset name that
doesn't exist, failing with "no asset found matching ...".

Pin the lookup to the engine release tag (the extension's own
`CARGO_PKG_VERSION`, kept in sync with extension.toml via
tools/versions/zed.cfg) using `github_release_by_tag_name`, so the
extension version and the language server binary it downloads stay
locked together and the nightly line is ignored.

Also corrects a stale Cargo.lock version (0.218.0 -> 0.223.0).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@vercel

vercel Bot commented Jun 25, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
beps Ready Ready Preview, Comment Jun 25, 2026 8:52am
promptfiddle2 Ready Ready Preview, Comment Jun 25, 2026 8:52am
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
promptfiddle Skipped Skipped Jun 25, 2026 8:52am

Request Review

@coderabbitai

coderabbitai Bot commented Jun 25, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 5af7e748-8fa7-431b-8cb1-34cfb8682d7a

📥 Commits

Reviewing files that changed from the base of the PR and between 6105c59 and 9fdcc64.

⛔ Files ignored due to path filters (1)
  • engine/zed/Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (1)
  • engine/zed/src/lib.rs

📝 Walkthrough

Walkthrough

The engine language-server lookup now derives its GitHub release tag from the crate version and resolves the download from that fixed tag instead of the latest release pointer.

Changes

Pinned engine release lookup

Layer / File(s) Summary
Version-tagged release resolution
engine/zed/src/lib.rs
Defines a crate-version release tag and uses it in the GithubRelease path to fetch the matching GitHub release by exact tag name.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~5 minutes

Poem

A tiny hop, a version’s tune, 🐇
I nibble tags beneath the moon.
No “latest” breeze can blow me stray,
I hop to versions, safe and stay.
Zip! The release is pinned just right,
A tidy carrot in the night.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
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 (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the main change: pinning the Zed language server download to the engine release tag instead of latest.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

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

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch hellovai/fix-zed

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.

@github-actions

Copy link
Copy Markdown

⏭️ Performance benchmarks were skipped

Perf benchmarks (CodSpeed) are opt-in on pull requests — they no longer run on every push. They always run automatically after merge to canary/main.

To run them on this PR, do any of the following, then push a commit (or re-run CI):

  • Add RUN_CODSPEED=1 to the PR description, or
  • Include run-perf or /perf in the PR title or any commit message.

@sxlijin

sxlijin commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

#3853 should take care of this

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