Skip to content

Conversation

@akapug
Copy link
Member

@akapug akapug commented Nov 26, 2025

Ready for review Powered by Pull Request Badge

Summary

Pins llama-cpp-2 crate to exact version 0.1.102 to fix CI build failures on all PRs.

Problem

After the recent cargo update (commit b774aa9), llama-cpp-2 was upgraded from 0.1.102 to 0.1.127. Version 0.1.126+ introduced a breaking API change where the c_char type changed from *const i8 to *const u8, causing type mismatch errors:

error[E0308]: mismatched types
  --> llama-cpp-2-0.1.126/src/lib.rs:416:35
    |
416 |         let name = cstr_to_string(props.name);
    |                    -------------- ^^^^^^^^^^ expected `*const i8`, found `*const u8`

This affects all PRs during the :packages:graalvm:buildRustNativesForHost task in the local-ai package.

Solution

Pin the version exactly using =0.1.102 in Cargo.toml to prevent cargo from resolving to incompatible newer versions.

Changes

  • Cargo.toml: Changed version = "0.1.102" to version = "=0.1.102"
  • Cargo.lock: Downgraded from 0.1.127 to 0.1.102

Fixes

Fixes #1796

Version 0.1.126+ introduced a breaking API change where c_char type
changed from *const i8 to *const u8, causing type mismatch errors in
buildRustNativesForHost.

Fixes elide-dev#1796
@akapug akapug requested a review from sgammon as a code owner November 26, 2025 03:22
@socket-security
Copy link

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updatedcargo/​llama-cpp-2@​0.1.127 ⏵ 0.1.10210010093100100

View full report

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.

CI: llama-cpp-2 Rust crate build failure on all PRs

1 participant