Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Neon toolchain does not work with Rust 1.79.0 #104

Open
haaawk opened this issue Apr 22, 2024 · 1 comment
Open

Neon toolchain does not work with Rust 1.79.0 #104

haaawk opened this issue Apr 22, 2024 · 1 comment
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@haaawk
Copy link
Contributor

haaawk commented Apr 22, 2024

The build breaks with:

> cargo build --message-format=json | npm exec neon dist

   Compiling libsql-js v0.3.12 (/home/haaawk/libsql-js)
error: No artifacts were generated for crate libsqlibsql-js                                  
error: Broken pipe (os error 32)
warning: build failed, waiting for other jobs to finish..

This is due to the fact that 1.79.0-nightly (80d5b607d 2024-04-19) version of cargo does not have the following lines in JSON that were present in previous versions of cargo:

{"reason":"compiler-message","package_id":"path+file:///Users/haaawk/work/libsql-js-perf#libsql-js@0.3.12","manifest_path":"/Users/haaawk/work/libsql-js-perf/Cargo.toml","target":{"kind":["cdylib"],"crate_types":["cdylib"],"name":"libsql-js","src_path":"/Users/haaawk/work/libsql-js-perf/src/lib.rs","edition":"2021","doc":true,"doctest":false,"test":true},"message":{"rendered":"warning: unused variable:cx\n --> src/database.rs:290:24\n |\n290 | ...&self, cx: &mut FunctionContext) -> Option<Arc<Mutex<libsql::Connection>>> {\n | ^^ help: if this is intentional, prefix it with an underscore: _cx\n |\n = note: #[warn(unused_variables)] on by default\n\n","$message_type":"diagnostic","children":[{"children":[],"code":null,"level":"note","message":"#[warn(unused_variables)]on by default","rendered":null,"spans":[]},{"children":[],"code":null,"level":"help","message":"if this is intentional, prefix it with an underscore","rendered":null,"spans":[{"byte_end":11024,"byte_start":11022,"column_end":26,"column_start":24,"expansion":null,"file_name":"src/database.rs","is_primary":true,"label":null,"line_end":290,"line_start":290,"suggested_replacement":"_cx","suggestion_applicability":"MaybeIncorrect","text":[{"highlight_end":26,"highlight_start":24,"text":" fn get_conn(&self, cx: &mut FunctionContext) -> Option<Arc<Mutex<libsql::Connection>>> {"}]}]}],"code":{"code":"unused_variables","explanation":null},"level":"warning","message":"unused variable:cx","spans":[{"byte_end":11024,"byte_start":11022,"column_end":26,"column_start":24,"expansion":null,"file_name":"src/database.rs","is_primary":true,"label":null,"line_end":290,"line_start":290,"suggested_replacement":null,"suggestion_applicability":null,"text":[{"highlight_end":26,"highlight_start":24,"text":" fn get_conn(&self, cx: &mut FunctionContext) -> Option<Arc<Mutex<libsql::Connection>>> {"}]}]}}

{"reason":"compiler-message","package_id":"path+file:///Users/haaawk/work/libsql-js-perf#libsql-js@0.3.12","manifest_path":"/Users/haaawk/work/libsql-js-perf/Cargo.toml","target":{"kind":["cdylib"],"crate_types":["cdylib"],"name":"libsql-js","src_path":"/Users/haaawk/work/libsql-js-perf/src/lib.rs","edition":"2021","doc":true,"doctest":false,"test":true},"message":{"rendered":"warning: 2 warnings emitted\n\n","$message_type":"diagnostic","children":[],"code":null,"level":"warning","message":"2 warnings emitted","spans":[]}}

{"reason":"compiler-artifact","package_id":"path+file:///Users/haaawk/work/libsql-js-perf#libsql-js@0.3.12","manifest_path":"/Users/haaawk/work/libsql-js-perf/Cargo.toml","target":{"kind":["cdylib"],"crate_types":["cdylib"],"name":"libsql-js","src_path":"/Users/haaawk/work/libsql-js-perf/src/lib.rs","edition":"2021","doc":true,"doctest":false,"test":true},"profile":{"opt_level":"z","debuginfo":0,"debug_assertions":false,"overflow_checks":false,"test":false},"features":[],"filenames":["/Users/haaawk/work/libsql-js-perf/target/release/liblibsql_js.dylib"],"executable":null,"fresh":true}

@penberg
Copy link
Contributor

penberg commented Jun 17, 2024

I pinned Rust toolchain to 1.78.0 now in 0d64dd8, but we really need to update Neon bindings to work with 1.79.0.

@penberg penberg changed the title npm run build does not work with cargo 1.79.0-nightly (80d5b607d 2024-04-19) Neon toolchain does not work with Rust 1.79.0 Jun 17, 2024
@penberg penberg added bug Something isn't working help wanted Extra attention is needed labels Jun 17, 2024
penberg added a commit that referenced this issue Dec 5, 2024
Fixes build problems with recent Rust toolchain versions.

Fixes #104
penberg added a commit to tursodatabase/libsql that referenced this issue Dec 6, 2024
The JavaScript SDK is unfortunately stuck with Rust 1.78:

tursodatabase/libsql-js#104

We should fix that, but since that's hard, let's just once again paper
over it by fixing build on older Rust toolchains.
penberg added a commit to tursodatabase/libsql that referenced this issue Dec 6, 2024
The JavaScript SDK is unfortunately stuck with Rust 1.78:

tursodatabase/libsql-js#104

We should fix that, but since that's hard, let's just once again paper
over it by fixing build on older Rust toolchains.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants