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

The virtual machine (VM 0.5) does not collect packages with dependencies, except Python and Kivy #1542

Closed
HeaTTheatR opened this issue Dec 19, 2018 · 3 comments

Comments

@HeaTTheatR
Copy link

Versions

Description

Trying to build a package using virtual magic. Found that it is possible to build a package only with the following configuration:

requirements = python3, kivy==1.10.1

2018-12-19 4 07 23

But if I want to add other dependencies, I get errors:

requirements = python3, kivy==1.10.1, pil  # or pillow/Pillow

Result - FAIL:

[ERROR]:   Didn't find any valid dependency graphs.
[ERROR]:   This means that some of your requirements pull in conflicting dependencies.
[ERROR]:   Exiting.

2018-12-19 4 16 39

Logs

[INFO]:    Recipe kivy: version "1.10.1" requested
[INFO]:    Will compile for the following archs: armeabi-v7a
[INFO]:    Found Android API target in $ANDROIDAPI: 27
[INFO]:    Available Android APIs are (13, 19, 21, 26, 27)
[INFO]:    Requested API target 27 is available, continuing.
[INFO]:    Found NDK dir in $ANDROIDNDK: /home/kivy/Android/android-ndk-r16b
[INFO]:    Got NDK version from $ANDROIDNDKVER: r9c
[WARNING]: NDK API target was not set manually, using the default of 21 = min(android-api=27, default ndk-api=21)
[INFO]:    Using Google NDK r9c
[INFO]:    Found virtualenv at /usr/local/bin/virtualenv
[INFO]:    ccache is missing, the build will not be optimized in the future.
[INFO]:    Found the following toolchain versions: ['4.9']
[INFO]:    Picking the latest gcc toolchain, here 4.9
[INFO]:    No existing dists meet the given requirements!
[INFO]:    No dist exists that meets your requirements, so one will be built.
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import TargetPythonRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.toolchain import shprint, current_directory
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3/__init__.py:3: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.logger import logger, info, error
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3/__init__.py:4: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.util import ensure_dir, walk_valid_filens
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3/__init__.py:5: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from os.path import exists, join, dirname
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3/__init__.py:6: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from os import environ
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3/__init__.py:7: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import glob
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3/__init__.py:8: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import sh
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/hostpython3/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.toolchain import Recipe, shprint, info
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/hostpython3/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.util import ensure_dir, current_directory
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/hostpython3/__init__.py:3: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from os.path import join, exists
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/hostpython3/__init__.py:4: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import sh
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/kivy/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import CythonRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/kivy/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.toolchain import current_directory, shprint
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/kivy/__init__.py:3: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from os.path import exists, join, basename
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/kivy/__init__.py:4: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import sh
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/kivy/__init__.py:5: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import glob
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pyjnius/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import CythonRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pyjnius/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.toolchain import shprint, current_directory, info
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pyjnius/__init__.py:3: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.patching import will_build
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pyjnius/__init__.py:4: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import sh
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pyjnius/__init__.py:5: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from os.path import join
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/six/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import PythonRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python2/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import TargetPythonRecipe, Recipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python2/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.toolchain import shprint, current_directory, info
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python2/__init__.py:3: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.patching import (is_darwin, is_api_gt,
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python2/__init__.py:5: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from os.path import exists, join, realpath
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python2/__init__.py:6: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from os import walk
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python2/__init__.py:7: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import glob
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python2/__init__.py:8: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import sh
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3crystax/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import TargetPythonRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3crystax/__init__.py:3: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.toolchain import shprint
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3crystax/__init__.py:4: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.logger import info, error
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3crystax/__init__.py:5: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.util import ensure_dir, temp_directory
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3crystax/__init__.py:6: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from os.path import exists, join
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/python3crystax/__init__.py:7: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import sh
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/genericndkbuild/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import BootstrapNDKRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/genericndkbuild/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.toolchain import current_directory, shprint
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/genericndkbuild/__init__.py:3: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import sh
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/sdl2/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import BootstrapNDKRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/sdl2/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.toolchain import current_directory, shprint
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/sdl2/__init__.py:3: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import sh
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/sdl/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import BootstrapNDKRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/sdl/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.toolchain import current_directory, info, shprint
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/sdl/__init__.py:3: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from os.path import exists, join
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/sdl/__init__.py:4: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import sh
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/sdl2_image/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import BootstrapNDKRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/sdl2_image/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.patching import is_arch
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/sdl2_mixer/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import BootstrapNDKRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/sdl2_ttf/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import BootstrapNDKRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pygame_bootstrap_components/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import BootstrapNDKRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pygame_bootstrap_components/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.toolchain import current_directory, shprint, info
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pygame_bootstrap_components/__init__.py:3: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from os.path import exists, join
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pygame_bootstrap_components/__init__.py:4: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import sh
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pygame_bootstrap_components/__init__.py:5: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import glob
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pygame/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import Recipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pygame/__init__.py:3: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.util import current_directory, ensure_dir
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pygame/__init__.py:4: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.logger import debug, shprint, info, warning
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pygame/__init__.py:5: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from os.path import join
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pygame/__init__.py:6: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import sh
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pygame/__init__.py:7: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import glob
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pil/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from os.path import join
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/pil/__init__.py:3: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import CompiledComponentsPythonRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/jpeg/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import NDKRecipe
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/jpeg/__init__.py:2: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.logger import shprint
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/jpeg/__init__.py:3: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.util import current_directory
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/jpeg/__init__.py:4: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from os.path import join, exists
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/jpeg/__init__.py:5: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  import sh
/home/kivy/Repos/python-for-android/pythonforandroid/recipes/png/__init__.py:1: RuntimeWarning: Parent module 'pythonforandroid.recipes' not found while handling absolute import
  from pythonforandroid.recipe import NDKRecipe
[ERROR]:   Didn't find any valid dependency graphs.
[ERROR]:   This means that some of your requirements pull in conflicting dependencies.
[ERROR]:   Exiting.

Another example of dependency is:

requirements = python3, kivy==1.10.1, git+https://github.com/HeaTTheatR/KivyMD.git

or

requirements = python3, kivy==1.10.1, plyer

Result - FAIL:

The path python3.7 (from --python=python3.7) does not exist

2018-12-19 4 20 48

###Logs

...

[INFO]:    Postbuilding kivy for armeabi-v7a
[INFO]:    # Installing pure Python modules
[INFO]:    The requirements (plyer) don't have recipes, attempting to install them with pip
[INFO]:    If this fails, it may mean that the module has compiled components and needs a recipe.
[INFO]:    -> directory context /home/kivy/Downloads/KivyMD/demos/kitchen_sink/.buildozer/android/platform/build/build
[INFO]:    -> running virtualenv --python=python3.7 venv
Exception in thread background thread for pid 3415:
Traceback (most recent call last):
  File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner
    self.run()
  File "/usr/lib/python2.7/threading.py", line 754, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/home/kivy/.local/lib/python2.7/site-packages/sh.py", line 2170, in background_thread
    handle_exit_code(exit_code)
  File "/home/kivy/.local/lib/python2.7/site-packages/sh.py", line 1929, in fn
    return self.command.handle_command_exit_code(exit_code)
  File "/home/kivy/.local/lib/python2.7/site-packages/sh.py", line 672, in handle_command_exit_code
    raise exc
ErrorReturnCode_3: 

  RAN: /usr/local/bin/virtualenv --python=python3.7 venv

  STDOUT:
The path python3.7 (from --python=python3.7) does not exist


  STDERR:


                                                                    Traceback (most recent call last):                 
  File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/home/kivy/Repos/python-for-android/pythonforandroid/toolchain.py", line 1033, in <module>
    main()
  File "/home/kivy/Repos/python-for-android/pythonforandroid/toolchain.py", line 1029, in main
    ToolchainCL()
  File "/home/kivy/Repos/python-for-android/pythonforandroid/toolchain.py", line 551, in __init__
    getattr(self, args.subparser_name.replace('-', '_'))(args)
  File "/home/kivy/Repos/python-for-android/pythonforandroid/toolchain.py", line 149, in wrapper_func
    build_dist_from_args(ctx, dist, args)
  File "/home/kivy/Repos/python-for-android/pythonforandroid/toolchain.py", line 189, in build_dist_from_args
    build_recipes(build_order, python_modules, ctx)
  File "pythonforandroid/build.py", line 662, in build_recipes
  File "pythonforandroid/build.py", line 683, in run_pymodules_install
  File "pythonforandroid/logger.py", line 178, in shprint
  File "/home/kivy/.local/lib/python2.7/site-packages/sh.py", line 720, in next
    self.wait()
  File "/home/kivy/.local/lib/python2.7/site-packages/sh.py", line 651, in wait
    self.handle_command_exit_code(exit_code)
  File "/home/kivy/.local/lib/python2.7/site-packages/sh.py", line 672, in handle_command_exit_code
    raise exc
sh.ErrorReturnCode_3: 

  RAN: /usr/local/bin/virtualenv --python=python3.7 venv

  STDOUT:
The path python3.7 (from --python=python3.7) does not exist

buildozer.spec

android.api = 27
android.minapi = 21
android.sdk = 28
android.ndk_path = /home/kivy/Android/android-ndk-r16b/
android.sdk_path = /home/kivy/Android/android-sdk-28/
android.arch = armeabi-v7a

@homdx
Copy link

homdx commented Jan 9, 2019

Probe install package in VM:

sudo apt-get install python3.7-venv

and probe again.

My fix in pull request to @Jonast repository:
https://github.com/JonasT/p4a-build-spaces/pull/5

@homdx
Copy link

homdx commented Jan 11, 2019

Please, check this pull request, provided by @Jonast #1577
and answer where.

(This is no need now: sudo apt-get install python3.7-venv)

@AndreMiras
Copy link
Member

Yes before that PR we could either match it by installing host python3.7 or use python3==3.6.8 as target python dependency.

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

3 participants