Skip to content

Cannot build APK with python3crystax and flask - conflicting dependencies #1041

Closed

Description

@tito

@kchomski commented on Wed Mar 01 2017

Hi,

It's not possible to build APK when python3crystax and flask are both in requirements (or maybe I am doing something terribly wrong).
From what I can see the problem comes from conflicting dependencies in recipes: flask depends on (python2 OR python3crystax) AND setuptools, but setuptools depends only on python2, which conflicts with python3crystax.

[INFO]:    Will compile for the following archs: armeabi-v7a
[INFO]:    Found Android API target in $ANDROIDAPI
[INFO]:    Available Android APIs are (19)
[INFO]:    Requested API target 19 is available, continuing.
[INFO]:    Found NDK dir in $ANDROIDNDK
[INFO]:    Got NDK version from $ANDROIDNDKVER
[WARNING]: NDK version was set as r10.3.2, but checking the NDK dir claims it is 10.3.2.
[WARNING]: The build will try to continue, but it may fail and you should check that your setting is correct.
[WARNING]: If the NDK dir result is correct, you don't need to manually set the NDK ver.
[INFO]:    Using Crystax NDK r10.3.2
[INFO]:    Found virtualenv at /usr/local/bin/virtualenv
[INFO]:    Found the following toolchain versions: ['4.9', '5', 'clang3.6', 'clang3.7']
[INFO]:    Picking the latest gcc toolchain, here 5
[INFO]:    No existing dists meet the given requirements!
[INFO]:    No dist exists that meets your requirements, so one will be built.
[INFO]:    Bootstrap requires recipes ['genericndkbuild', ('python2', 'python3crystax')]
[INFO]:    Loaded recipe flask (depends on [('python2', 'python3crystax'), 'setuptools'])
[INFO]:    Loaded recipe genericndkbuild (depends on [('python2', 'python3crystax')], conflicts ['sdl2', 'pygame', 'sdl'])
[INFO]:    Loaded recipe python3crystax (depends on ['hostpython3crystax'], conflicts ['python2', 'python3'])
[INFO]:    Loaded recipe setuptools (depends on ['python2'])
[INFO]:    Loaded recipe hostpython3crystax (depends on [], conflicts ['hostpython2'])
[INFO]:    Loaded recipe python2 (depends on ['hostpython2'], conflicts ['python3crystax', 'python3'])
[WARNING]: python2 conflicts with python3crystax, but both have been included or pulled into the requirements.
[WARNING]: Due to this conflict the build cannot continue, exiting.

@tito commented on Mon May 01 2017

This is an issue with python-for-android itself. I'm moving it to the proper project.

Activity

  1. yingshaoxo commented on May 28, 2017

    @yingshaoxo
    Contributor

    I got the same problem too.

    Loaded recipe setuptools (depends on ['python2'])
    hostpython3crystax conflicts with hostpython2, but both have been included or pulled into the requirements.
    

    Here is the kivy builder for python3 I am using now:
    https://drive.google.com/open?id=0B8M6pE4UPOI5ZUxodEJFRTBLOW8

  2. AustinHasten commented on Jun 4, 2017

    @AustinHasten

    Same issue here being caused by the requests package pulling in python2.

  3. roquebetioljr commented on Sep 13, 2017

    @roquebetioljr

    I got the same problem using pyopenssl and python3crystax.

  4. planrich commented on Oct 5, 2017

    @planrich

    One possible issue that affects me as well is that python3crystax or hostpython3crystax do not allow to rebuild python3.X using the NDK. At least a comment in recipies/python3crystax/init.py says so. Unsure why but it looks like the crystax NDK does not link to openssl or sqlite...

  5. inclement commented on Oct 5, 2017

    @inclement
    Member

    @planrich You can rebuild the crystax python, and I think it will build with openssl and/or sqlite if available (also built with crystax), but python-for-android has no code for that right now. The issue you've commented on is different, and arises from flask bringing in dependencies that cannot be reconciled.

  6. planrich commented on Oct 5, 2017

    @planrich

    yes, mainly setuptools (which is needed by flask, or cffi or cryptography, ...). which does not list python3crytax in its dependencies. so if you add it you will hit issues.

    • hostpython3crystax recipe: missing get_build_dir(self, arch=None) as in hostpython2, otherwise hostpython_location property of a recipe instance will just return 'python3.5' which is not helpful
    • setuptools has a very anchient version

    As I'm not familiar with python-for-android, I'm maybe digging at the wrong spot...

  7. inclement commented on Oct 5, 2017

    @inclement
    Member

    As I'm not familiar with python-for-android, I'm maybe digging at the wrong spot...

    @planrich Those are probably the right things to look at, although I don't know for sure without seeing the logs.

  8. inclement commented on Jan 30, 2019

    @inclement
    Member

    Closing as stale, this may well have been fixed by all the changes since it was raised.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions