Brendonovich / prisma-client-rust

Type-safe database access for Rust
https://prisma.brendonovich.dev
Apache License 2.0
1.84k stars 108 forks source link

fails to compile with the nightly toolchain #241

Closed chaoky closed 1 year ago

chaoky commented 1 year ago

the latest version (0.6.3) doesn't work with nightly

#cargo.toml
[dependencies.prisma-client-rust]
git = "https://github.com/Brendonovich/prisma-client-rust"
tag = "0.6.3"
default-features = false
features = ["postgresql"]

[dependencies.prisma-client-rust-cli]
git = "https://github.com/Brendonovich/prisma-client-rust"
tag = "0.6.3"
default-features = false
features = ["postgresql"]
cargo build
...

Compiling miniz_oxide v0.6.2
error: there is no argument named `err_str`
   --> /home/lordie/.cargo/git/checkouts/prisma-engines-8e1416dd0e571d11/06a1b97/libs/datamodel/core/src/configuration/datasource.rs:94:44
    |
94  |   ...   let s = indoc::formatdoc! {"
    |  __________________________________^
95  | | ...       {err_str}
96  | | ...
97  | | ...       To use a URL with protocol `prisma://` the Data Proxy must be enabled via `prisma generate --dat...98  | | ...
99  | | ...       More information about Data Proxy: https://pris.ly/d/data-proxy
100 | | ...   "};
    | |_______^
    |
    = note: did you intend to capture a variable `err_str` from the surrounding scope?
    = note: to avoid ambiguity, `format_args!` cannot capture variables when the format string is expanded from a macro

   Compiling tokio-rustls v0.23.4
   Compiling flate2 v1.0.25
error: could not compile `datamodel` due to previous error
warning: build failed, waiting for other jobs to finish...

manually cloning https://github.com/prisma/prisma-engines at 06a1b97 gave me the same erros (as expected)

Brendonovich commented 1 year ago

Given how large the prisma engines are, I've said before that I'm not interested in supporting nightly (#88). Maintaining a fork for database connector feature gating is already a lot of overhead, I don't want to make large changes or update dependencies just to support nightly.

proudmuslim-dev commented 1 year ago

@Brendonovich Would you be willing to fix this issue in exchange for some payment? Note that I can only pay via Monero at this time

Normally I don't make offers like this, and I'm sorry in advance if it offends you but I'm just in a hurry with a project I'm writing and I'd rather not lock on to an older nightly version (I need to stay on nightly due to other requirements the project has)

Brendonovich commented 1 year ago

@proudmuslim-dev I appreciate the offer, but I'm more concerned about time than money for this issue. Committing to nightly support would just be another thing to spend time on, and it wouldn't benefit the place where I actually make money (Spacedrive). I'll speak to the Prisma team about supporting nightly but I can't promise anything.

proudmuslim-dev commented 1 year ago

@Brendonovich Fair enough, thank you

proudmuslim-dev commented 1 year ago

For those who wish to keep going on nightly, put this in your rust-toolchain.toml

[toolchain]
channel = "nightly-2022-12-29"

nightly-2022-12-29 is the latest version that will compile