Bug 1628005 (rust-criterion-plot) - Review Request: rust-criterion-plot - Criterion's plotting library
Summary: Review Request: rust-criterion-plot - Criterion's plotting library
Keywords:
Status: CLOSED WONTFIX
Alias: rust-criterion-plot
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Nobody's working on this, feel free to take it
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: rust-criterion
TreeView+ depends on / blocked
 
Reported: 2018-09-12 05:27 UTC by Igor Raits
Modified: 2019-03-19 20:56 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2019-01-28 16:11:35 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Igor Raits 2018-09-12 05:27:23 UTC
Spec URL: https://ignatenkobrain.fedorapeople.org/for-review/rust-criterion-plot.spec
SRPM URL: https://ignatenkobrain.fedorapeople.org/for-review/rust-criterion-plot-0.2.5-1.fc30.src.rpm
Description:
Criterion's plotting library.
Fedora Account System Username: ignatenkobrain

Comment 1 Robert-André Mauchin 🐧 2018-09-12 16:06:17 UTC
Same issue as before:

+ /usr/lib/rpm/redhat/brp-mangle-shebangs
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/Cargo.toml.orig is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/README.md is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/axis.rs is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/candlestick.rs is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/curve.rs is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** ERROR: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/data.rs has shebang which doesn't start with '/' ([allow(deprecated)])
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/display.rs is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/errorbar.rs is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/filledcurve.rs is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/grid.rs is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/key.rs is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/lib.rs is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/map.rs is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/prelude.rs is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/proxy.rs is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/share/cargo/registry/criterion-plot-0.2.5/src/traits.rs is executable but has empty or no shebang, removing executable bit
Erreur de construction de RPM :
BUILDSTDERR: erreur : Mauvais statut de sortie pour /var/tmp/rpm-tmp.tJaLtG (%install)
BUILDSTDERR:     Mauvais statut de sortie pour /var/tmp/rpm-tmp.tJaLtG (%install)
Child return code was: 1


It seems the whole crate is marked as executable. You should patch that.

find . -type f -exec chmod 0644 "{}" \;
find . -type d -exec chmod 0755 "{}" \;


Then a test fails:

running 5 tests
test src/lib.rs -  (line 236) ... FAILED
test src/lib.rs -  (line 14) ... ok
test src/lib.rs -  (line 167) ... ok
test src/lib.rs -  (line 314) ... ok
test src/lib.rs -  (line 81) ... ok
failures:
---- src/lib.rs -  (line 236) stdout ----
error[E0599]: no method named `arg` found for type `num_complex::Complex<f64>` in the current scope
  --> src/lib.rs:259:38
   |
24 | let phase = xs.iter().map(|&x| tf(x).arg() * 180. / PI);
   |                                      ^^^
error[E0599]: no method named `norm` found for type `num_complex::Complex<f64>` in the current scope
  --> src/lib.rs:260:42
   |
25 | let magnitude = xs.iter().map(|&x| tf(x).norm());
   |                                          ^^^^
thread 'src/lib.rs -  (line 236)' panicked at 'couldn't compile the test', librustdoc/test.rs:330:13
note: Run with `RUST_BACKTRACE=1` for a backtrace.
failures:
    src/lib.rs -  (line 236)
test result: FAILED. 4 passed; 1 failed; 0 ignored; 0 measured; 0 filtered out


I believe this is due to your bump of num_complex. It fails in Travis too: https://travis-ci.org/japaric/criterion.rs/builds/427526252

Comment 2 Robert-André Mauchin 🐧 2018-09-12 16:13:52 UTC
The issue in criterion plot is that default features are disabled for num-complex:

   num-complex = { version = "0.1", default-features = false }

This disables #[cfg(feature = "std") and thus norm and arg:

#[cfg(feature = "std")]
impl<T: Clone + Float> Complex<T> {
    /// Calculate |self|
    #[inline]
    pub fn norm(&self) -> T {
        self.re.hypot(self.im)
    }
    /// Calculate the principal Arg of self.
    #[inline]
    pub fn arg(&self) -> T {
        self.im.atan2(self.re)
    }

Comment 3 Igor Raits 2019-01-28 16:11:35 UTC
Let's package it later.

Nothing uses it now.

Comment 5 Robert-André Mauchin 🐧 2019-03-16 17:10:08 UTC
Koji scratch build: https://koji.fedoraproject.org/koji/taskinfo?taskID=33540836

Comment 7 Robert-André Mauchin 🐧 2019-03-16 17:16:36 UTC
Koji scratch build: https://koji.fedoraproject.org/koji/taskinfo?taskID=33541030


Note You need to log in before you can comment on or make changes to this bug.