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

Diesel v1.3.1 compilation failed #1737

Closed
2 tasks done
gdf8gdn8 opened this issue May 28, 2018 · 3 comments
Closed
2 tasks done

Diesel v1.3.1 compilation failed #1737

gdf8gdn8 opened this issue May 28, 2018 · 3 comments

Comments

@gdf8gdn8
Copy link

Setup

Versions

  • Rust:
    nightly-x86_64-apple-darwin unchanged - rustc 1.28.0-nightly (990d8aa74 2018-05-25)
  • Diesel:
    Package Installed Latest Needs update
    diesel_cli v1.2.0 v1.3.1 Yes
  • Database:
  • Operating System
    macos X 10.13.4

Feature Flags

  • diesel:

Problem Description

Build failed while compiling diesel_cli

What is the actual output?

Updating diesel_cli
Updating registry https://github.com/rust-lang/crates.io-index
Installing diesel_cli v1.3.1
Compiling unicode-xid v0.1.0
Compiling matches v0.1.6
Compiling pkg-config v0.3.11
Compiling libc v0.2.41
Compiling unicode-xid v0.0.4
Compiling pq-sys v0.4.5
Compiling void v1.0.2
Compiling num-traits v0.2.4
Compiling unicode-normalization v0.1.7
Compiling lazy_static v1.0.0
Compiling num-integer v0.1.38
Compiling cfg-if v0.1.3
Compiling rustc-demangle v0.1.8
Compiling regex v0.2.11
Compiling quote v0.3.15
Compiling percent-encoding v1.0.1
Compiling ucd-util v0.1.1
Compiling serde v1.0.62
Compiling utf8-ranges v1.0.0
Compiling bitflags v1.0.3
Compiling unicode-width v0.1.5
Compiling byteorder v1.2.3
Compiling ansi_term v0.11.0
Compiling remove_dir_all v0.5.1
Compiling vec_map v0.8.1
Compiling strsim v0.7.0
Compiling unicode-bidi v0.3.4
Compiling unreachable v1.0.0
Compiling proc-macro2 v0.4.3
Compiling proc-macro2 v0.3.8
Compiling synom v0.11.3
Compiling memchr v2.0.1
Compiling time v0.1.40
Compiling rand v0.4.2
Compiling atty v0.2.10
Compiling backtrace v0.3.8
Compiling regex-syntax v0.5.6
Compiling textwrap v0.9.0
Compiling libsqlite3-sys v0.9.1
Compiling mysqlclient-sys v0.2.3
Compiling thread_local v0.3.5
Compiling syn v0.11.11
Compiling aho-corasick v0.6.4
Compiling tempfile v3.0.2
Compiling error-chain v0.10.0
Compiling quote v0.6.2
Compiling quote v0.5.2
Compiling clap v2.31.2
Compiling syn v0.14.0
Compiling syn v0.13.11
Compiling chrono v0.4.2
Compiling idna v0.1.4
Compiling serde_derive v1.0.62
Compiling derive-error-chain v0.10.1
Compiling diesel_derives v1.3.0
Compiling url v1.7.0
Compiling dotenv v0.10.1
Compiling diesel v1.3.0
error[E0277]: the trait bound <expression::count::CountStar as expression::Expression>::SqlType: sql_types::ops::Add is not satisfied
--> /Users/uwe/.cargo/registry/src/github.com-1ecc6299db9ec823/diesel-1.3.0/src/expression/count.rs:58:39
|
58 | #[derive(Debug, Clone, Copy, QueryId, DieselNumericOps)]
| ^^^^^^^^^^^^^^^^ the trait sql_types::ops::Add is not implemented for <expression::count::CountStar as expression::Expression>::SqlType
|
= help: consider adding a where <expression::count::CountStar as expression::Expression>::SqlType: sql_types::ops::Add bound
= help: see issue #48214
= help: add #![feature(trivial_bounds)] to the crate attributes to enable

error[E0277]: the trait bound <expression::count::CountStar as expression::Expression>::SqlType: sql_types::ops::Sub is not satisfied
--> /Users/uwe/.cargo/registry/src/github.com-1ecc6299db9ec823/diesel-1.3.0/src/expression/count.rs:58:39
|
58 | #[derive(Debug, Clone, Copy, QueryId, DieselNumericOps)]
| ^^^^^^^^^^^^^^^^ the trait sql_types::ops::Sub is not implemented for <expression::count::CountStar as expression::Expression>::SqlType
|
= help: consider adding a where <expression::count::CountStar as expression::Expression>::SqlType: sql_types::ops::Sub bound
= help: see issue #48214
= help: add #![feature(trivial_bounds)] to the crate attributes to enable

error[E0277]: the trait bound <expression::count::CountStar as expression::Expression>::SqlType: sql_types::ops::Mul is not satisfied
--> /Users/uwe/.cargo/registry/src/github.com-1ecc6299db9ec823/diesel-1.3.0/src/expression/count.rs:58:39
|
58 | #[derive(Debug, Clone, Copy, QueryId, DieselNumericOps)]
| ^^^^^^^^^^^^^^^^ the trait sql_types::ops::Mul is not implemented for <expression::count::CountStar as expression::Expression>::SqlType
|
= help: consider adding a where <expression::count::CountStar as expression::Expression>::SqlType: sql_types::ops::Mul bound
= help: see issue #48214
= help: add #![feature(trivial_bounds)] to the crate attributes to enable

error[E0277]: the trait bound <expression::count::CountStar as expression::Expression>::SqlType: sql_types::ops::Div is not satisfied
--> /Users/uwe/.cargo/registry/src/github.com-1ecc6299db9ec823/diesel-1.3.0/src/expression/count.rs:58:39
|
58 | #[derive(Debug, Clone, Copy, QueryId, DieselNumericOps)]
| ^^^^^^^^^^^^^^^^ the trait sql_types::ops::Div is not implemented for <expression::count::CountStar as expression::Expression>::SqlType
|
= help: consider adding a where <expression::count::CountStar as expression::Expression>::SqlType: sql_types::ops::Div bound
= help: see issue #48214
= help: add #![feature(trivial_bounds)] to the crate attributes to enable

error: aborting due to 4 previous errors

For more information about this error, try rustc --explain E0277.
error: Could not compile 'diesel'.
warning: build failed, waiting for other jobs to finish...
error: failed to compile 'diesel_cli v1.3.1', intermediate artifacts can be found at /var/folders/h4/h_9ztwls6bdfkqycs5dbh3lw0000gt/T/cargo-installNmh5Yy

Caused by:
build failed

Updated 0 packages.
Failed to update diesel_cli.
`

Are you seeing any additional errors?

Steps to reproduce

Checklist

  • I have already looked over the issue tracker for similar issues.
  • This issue can be reproduced on Rust's stable channel. (Your issue will be
    closed if this is not the case)
@Eijebong
Copy link
Member

It's a rustc bug, see #1700 #1701 #1705 #1711 #1729, #1730, #1731, rust-lang/rust#50825 and rust-lang/rust#51042

@apiraino
Copy link

To add to the previous comment, I've kind of worked around this compilation error setting a previous nightly version:

rustup override set nightly-2018-05-15

@sgrif
Copy link
Member

sgrif commented May 30, 2018

@gdf8gdn8 Please do not check "This issue can be reproduced on Rust's stable channel." if that is not the case.

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

No branches or pull requests

4 participants