Skip to content

Commit f542f03

Browse files
authored
Switch to minimum supported Rust version compatible resolver (#2239)
The url 2.5.4+ crate pulls idna 1.x -> idna_adapter -> icu_* 2.2.0, which require rustc 1.86. A fresh dependency resolution (e.g. the Docker build, which did not pass --locked) would select those and fail against the 1.85.0 toolchain pinned in rust-toolchain.toml. Bump the workspace to resolver = "3". With no rust-version declared, cargo's MSRV-aware resolver falls back to the installed toolchain version (1.85.0, per rust-toolchain.toml) and resolves to the latest compatible deps. Also pass --locked in the Dockerfile so the image builds the exact pinned dependency tree.
2 parents e4beaca + 46e2c12 commit f542f03

12 files changed

Lines changed: 29 additions & 5 deletions

File tree

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[workspace]
2-
resolver = "2"
2+
resolver = "3"
33
members = [
44
"bindings/c",
55
"bindings/wasm",

Dockerfile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,15 +28,15 @@ FROM chef AS builder
2828
ARG BUILD_DEBUG=false
2929
ENV CARGO_PROFILE_RELEASE_DEBUG=$BUILD_DEBUG
3030
COPY --from=planner /recipe.json recipe.json
31-
RUN cargo chef cook --release --recipe-path recipe.json
31+
RUN cargo chef cook --release --locked --recipe-path recipe.json
3232
COPY . .
3333
ARG ENABLE_FEATURES=""
3434
RUN if [ "$ENABLE_FEATURES" == "" ]; then \
35-
cargo build -p libsql-server --release ; \
35+
cargo build -p libsql-server --release --locked ; \
3636
else \
37-
cargo build -p libsql-server --features "$ENABLE_FEATURES" --release ; \
37+
cargo build -p libsql-server --features "$ENABLE_FEATURES" --release --locked ; \
3838
fi
39-
RUN cargo build -p bottomless-cli --release
39+
RUN cargo build -p bottomless-cli --release --locked
4040

4141
# official gosu install instruction (https://github.com/tianon/gosu/blob/master/INSTALL.md)
4242
FROM debian:bullseye-slim as gosu

libsql-sqlite3/ext/crr/rs/bundle/Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,3 +41,5 @@ omit_load_extension = [
4141
"crsql_fractindex_core/omit_load_extension",
4242
"crsql_core/omit_load_extension"
4343
]
44+
45+
[workspace]

libsql-sqlite3/ext/crr/rs/bundle_static/Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,5 @@ static = [
3333
omit_load_extension = [
3434
"crsql_bundle/omit_load_extension"
3535
]
36+
37+
[workspace]

libsql-sqlite3/ext/crr/rs/core/Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,3 +30,5 @@ libsql = []
3030
loadable_extension = ["sqlite_nostd/loadable_extension"]
3131
static = ["sqlite_nostd/static"]
3232
omit_load_extension = ["sqlite_nostd/omit_load_extension"]
33+
34+
[workspace]

libsql-sqlite3/ext/crr/rs/fractindex-core/Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,5 @@ target = "wasm32-unknown-emscripten"
2929
loadable_extension = ["sqlite_nostd/loadable_extension"]
3030
static = ["sqlite_nostd/static"]
3131
omit_load_extension = ["sqlite_nostd/omit_load_extension"]
32+
33+
[workspace]

libsql-sqlite3/ext/crr/rs/integration_check/Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,5 @@ cc = "1.0"
2424
libsql = ["crsql_bundle/libsql"]
2525
static = []
2626
omit_load_extension = []
27+
28+
[workspace]

libsql-sqlite3/ext/crr/rs/sqlite-rs-embedded/sqlite3_allocator/Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,5 @@ sqlite3_capi = {version="0.1.0", path="../sqlite3_capi"}
1616

1717
# dev dependencies for examples
1818
[dev-dependencies]
19+
20+
[workspace]

libsql-sqlite3/ext/crr/rs/sqlite-rs-embedded/sqlite3_capi/Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,5 @@ bindgen = "0.68.1"
1616
loadable_extension = []
1717
static = []
1818
omit_load_extension = []
19+
20+
[workspace]

libsql-sqlite3/ext/crr/rs/sqlite-rs-embedded/sqlite_nostd/Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,3 +17,5 @@ num-derive = "0.4.1"
1717
loadable_extension = ["sqlite3_capi/loadable_extension"]
1818
static = ["sqlite3_capi/static"]
1919
omit_load_extension = ["sqlite3_capi/omit_load_extension"]
20+
21+
[workspace]

0 commit comments

Comments
 (0)