llogiq / flame

An intrusive flamegraph profiling tool for rust.
Apache License 2.0
694 stars 30 forks source link

Side-effect on `std::convert::Into<_>` introduced in 0.1.12 #22

Closed behnam closed 6 years ago

behnam commented 7 years ago

As the 0.1.12 update yesterday, I noticed that building lib unit tests is failing in unicode-bidi with flame_it feature. I went back and minimized the changes for the break, which actually reduced to only extern crate flame;, and only happening for =0.1.12.

Here's the commit causing error on a stable unicode-bidi build: https://github.com/behnam/rust-unicode-bidi/commit/6e6fc7890bca1e1fe952e69508dba9369e1d37b1

Here's the error:

error[E0283]: type annotations required: cannot resolve `level::Level: std::convert::Into<_>`
   --> src/level.rs:331:31
    |
331 |         assert_eq!(1u8, level.into());
    |                               ^^^^

error: aborting due to previous error

from https://travis-ci.org/behnam/rust-unicode-bidi/jobs/243806493#L259

I have no idea how flame can cause this in a module that doesn't use any of the traits. What do you think, @TyOverby ?

TyOverby commented 7 years ago

Could it be an issue with flame changing transitive dependencies?

behnam commented 7 years ago

Hum... not sure what you mean by transitive dependencies.

I'm looking at git diff 590014d e1cf412 and can't find anything suspicious.

TyOverby commented 7 years ago

@behnam I mean, could adding flame as a dependency change the versions of other dependencies in your project?

TyOverby commented 7 years ago

@behnam: any update on this? I don't think that this is the fault of bincode.

behnam commented 7 years ago

No updates here, @TyOverby . I guess it's a version conflict for serde_derive stuff, but I don't find it.

TyOverby commented 7 years ago

If this still repros for you, could you send me the contents of your Cargo.lock file before and after?

Also try building flame with and without the json feature enabled.

behnam commented 7 years ago

Thanks, @TyOverby. Here are the files:

behnam commented 7 years ago

Also, I disabled default flame features, but still got the same error.

TyOverby commented 6 years ago

your before/after cargo.lock.toml files are identical

TyOverby commented 6 years ago

Closing due to inactivity; please reopen if this is still an issue.