Skip to content

PyPi installation on CentOS 7 fails #9

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

Closed
pevogam opened this issue Jun 14, 2018 · 3 comments
Closed

PyPi installation on CentOS 7 fails #9

pevogam opened this issue Jun 14, 2018 · 3 comments
Labels
bug Something isn't working

Comments

@pevogam
Copy link
Collaborator

pevogam commented Jun 14, 2018

I am trying to install autopy in an as standard way as possible:

yum install rust cargo
pip3 install -U setuptools-rust
pip3 install -U autopy

But this resulted in an error like:

Collecting autopy
Using cached https://files.pythonhosted.org/packages/cb/99/9203ea5442f3bd52695fce191305eeb6de63ff29a9a05d0c5ecb60ec4a69/autopy-1.0.1.tar.gz
Installing collected packages: autopy
Running setup.py install for autopy ... error
    Complete output from command /usr/bin/python3.4 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-8mrzr7a6/autopy/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-wsql0xxd-record/install-record.txt --single-version-externally-managed --compile:
    running install
    running build
    running build_py
    creating build
    creating build/lib.linux-x86_64-3.4
    creating build/lib.linux-x86_64-3.4/autopy
    copying autopy/__init__.py -> build/lib.linux-x86_64-3.4/autopy
    running build_ext
    running build_rust
        Updating registry `https://github.com/rust-lang/crates.io-index`
    Downloading png v0.12.0
    Downloading pyo3cls v0.2.1
    Downloading rayon v1.0.1
    Downloading proc-macro2 v0.2.3
    Downloading core-foundation v0.5.1
    Downloading syn v0.11.11
    Downloading scoped_threadpool v0.1.9
    Downloading num-iter v0.1.35
    Downloading fuchsia-zircon v0.3.3
    Downloading either v1.5.0
    Downloading nodrop v0.1.12
    Downloading lazy_static v1.0.0
    Downloading thread_local v0.3.5
    Downloading regex-syntax v0.5.5
    Downloading gif v0.10.0
    Downloading deflate v0.7.18
    Downloading unicode-xid v0.0.4
    Downloading fuchsia-zircon-sys v0.3.3
    Downloading malloc_buf v0.0.6
    Downloading rayon-core v1.4.0
    Downloading winapi v0.3.4
    Downloading winapi-x86_64-pc-windows-gnu v0.4.0
    Downloading libc v0.2.40
    Downloading foreign-types v0.3.2
    Downloading inflate v0.4.2
    Downloading syn v0.12.15
    Downloading x11 v2.17.5
    Downloading num-traits v0.2.2
    Downloading adler32 v1.0.2
    Downloading num-rational v0.1.42
    Downloading rand v0.4.2
    Downloading unreachable v1.0.0
    Downloading regex v0.2.10
    Downloading pyo3 v0.2.6
    Downloading foreign-types-shared v0.1.1
    Downloading num_cpus v1.8.0
    Downloading bitflags v1.0.2
    Downloading cocoa v0.14.0
    Downloading pkg-config v0.3.11
    Downloading version_check v0.1.3
    Downloading color_quant v1.0.0
    Downloading log v0.4.1
    Downloading ucd-util v0.1.1
    Downloading crossbeam-deque v0.2.0
    Downloading aho-corasick v0.6.4
    Downloading crossbeam-epoch v0.3.1
    Downloading spin v0.4.8
    Downloading void v1.0.2
    Downloading image v0.19.0
    Downloading byteorder v1.2.2
    Downloading core-graphics v0.13.0
    Downloading lzw v0.10.0
    Downloading synom v0.11.3
    Downloading num-derive v0.2.0
    Downloading jpeg-decoder v0.1.14
    Downloading autopilot v0.1.1
    Downloading unicode-xid v0.1.0
    Downloading winapi-i686-pc-windows-gnu v0.4.0
    Downloading quote v0.4.2
    Downloading quote v0.3.15
    Downloading block v0.1.6
    Downloading arrayvec v0.4.7
    Downloading utf8-ranges v1.0.0
    Downloading num-integer v0.1.36
    Downloading cfg-if v0.1.2
    Downloading memoffset v0.2.1
    Downloading memchr v2.0.1
    Downloading log v0.3.9
    Downloading scopeguard v0.3.3
    Downloading objc v0.2.2
    Downloading crossbeam-utils v0.2.2
    Downloading core-foundation-sys v0.5.1
    cargo rustc --lib --manifest-path Cargo.toml --features pyo3/extension-module pyo3/python3 --release -- --crate-type cdylib
    Compiling cfg-if v0.1.2
    Compiling nodrop v0.1.12
    Compiling lazy_static v1.0.0
    Compiling scopeguard v0.3.3
    Compiling memoffset v0.2.1
    Compiling unicode-xid v0.1.0
    Compiling rayon-core v1.4.0
    Compiling libc v0.2.40
    Compiling void v1.0.2
    Compiling ucd-util v0.1.1
    Compiling regex v0.2.10
    Compiling num-traits v0.2.2
    Compiling either v1.5.0
    Compiling byteorder v1.2.2
    Compiling adler32 v1.0.2
    Compiling utf8-ranges v1.0.0
    Compiling pkg-config v0.3.11
    Compiling unicode-xid v0.0.4
    Compiling quote v0.3.15
    Compiling color_quant v1.0.0
    Compiling version_check v0.1.3
    Compiling bitflags v1.0.2
    Compiling lzw v0.10.0
    Compiling scoped_threadpool v0.1.9
    Compiling spin v0.4.8
    error[E0554]: #![feature] may not be used on the stable release channel
    --> /root/.cargo/registry/src/github.com-1ecc6299db9ec823/spin-0.4.8/src/lib.rs:6:30
    |
    6 | #![cfg_attr(feature = "asm", feature(asm))]
    |                              ^^^^^^^^^^^^^
    
    error[E0554]: #![feature] may not be used on the stable release channel
    --> /root/.cargo/registry/src/github.com-1ecc6299db9ec823/spin-0.4.8/src/lib.rs:7:42
    |
    7 | #![cfg_attr(feature = "core_intrinsics", feature(core_intrinsics))]
    |                                          ^^^^^^^^^^^^^^^^^^^^^^^^^
    
    error[E0554]: #![feature] may not be used on the stable release channel
    --> /root/.cargo/registry/src/github.com-1ecc6299db9ec823/spin-0.4.8/src/lib.rs:8:35
    |
    8 | #![cfg_attr(feature = "const_fn", feature(const_fn, const_unsafe_cell_new, const_atomic_usize_new))]
    |                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    
    error: aborting due to 3 previous errors
    
    For more information about this error, try `rustc --explain E0554`.
    error: Could not compile `spin`.
    warning: build failed, waiting for other jobs to finish...
    error: build failed
    error: cargo failed with code: 101

Do you think it could be a missing package or something else?

@msanders
Copy link
Contributor

msanders commented Jun 15, 2018

Hi @pevogam. Thanks for the report. Are you using the latest rust nightly?

@pevogam
Copy link
Collaborator Author

pevogam commented Jun 16, 2018

No, I am only using the few steps described above. I would prefer to have a more stable release rather than experimental nightly builds and an installation process that is more compatible with the system-wide package manager (in this case RPM) if possible.

These are the versions of the relevant packages:

# pip3 list installed | grep rust
setuptools-rust  0.10.1 
# yum list installed | grep -iE "rust|cargo"
cargo.x86_64                           1.26.0-1.el7                    @epel    
rust.x86_64                            1.26.0-1.el7                    @epel    
rust-std-static.x86_64                 1.26.0-1.el7                    @epel 

Even if the versions are somewhat archaic (typical of CentOS), I still tried to make an exception by pulling the latest versions through pip but this fails as well. Isn't the PyPI package supposed to resolve its own dependencies including required versions? I guess the setup with the Rust language is a bit more elaborate so it is not possible and even the automated resolution which would succeed on Fedora fails here.

The most default (even if less secure) method

curl https://sh.rustup.rs -sSf | sh

succeeds and also adds rustup which is currently not packaged in an RPM but is very far from canonical.

Conclusion from all of this is that this is a CentOS problem related to the RPM-PyPI version compatibility and is not a bug of AutoPy. Thanks though!

@pevogam pevogam closed this as completed Jun 16, 2018
@msanders
Copy link
Contributor

Agreed @pevogam. We are currently blocked on using Rust stable due to the requirements given by PyO3 (documented here). Glad you were able to find a resolution.

@msanders msanders added the bug Something isn't working label Sep 3, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants