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

AttributeError: 'module' object has no attribute 'recipe' #907

Closed
nesergen opened this issue Oct 13, 2016 · 1 comment
Closed

AttributeError: 'module' object has no attribute 'recipe' #907

nesergen opened this issue Oct 13, 2016 · 1 comment

Comments

@nesergen
Copy link

I have tryed to compile my first apk by p4a, but got the error. What I have done wrong&

@sergen-pc:~$ p4a apk --private /home/sergen/PythonExp/kivy_exp/TRADE_sql/ --package=org.example.myapp --name "My application" --version 0.1 --bootstrap=sdl2 --requirements=python2,kivy,plyer, sqlite3 --debug --sdk_dir /home/sergen/Android/SDK_Android/ --android_api=17 --ndk_dir /home/sergen/Android/android-ndk-r9c/ --ndk_version=r9c
[INFO]:    Will compile for the following archs: armeabi
[INFO]:    Getting Android API version from user argument
[INFO]:    Available Android APIs are (10, 14, 16, 17, 18, 19)
[INFO]:    Requested API target 17 is available, continuing.
[INFO]:    Getting NDK dir from from user argument
[INFO]:    Got NDK version from from user argument
[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.6', '4.8', 'clang3.3']
[INFO]:    Picking the latest gcc toolchain, here 4.8
[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 ['sdl2', ('python2', 'python3crystax')]
[WARNING]: Failed to import recipe named ; the recipe exists but appears broken.
[WARNING]: Exception was:
Traceback (most recent call last):
  File "/usr/local/bin/p4a", line 9, in <module>
    load_entry_point('python-for-android==0.4', 'console_scripts', 'p4a')()
  File "/usr/local/lib/python2.7/dist-packages/pythonforandroid/toolchain.py", line 834, in main
    ToolchainCL()
  File "/usr/local/lib/python2.7/dist-packages/pythonforandroid/toolchain.py", line 489, in __init__
    getattr(self, args.subparser_name.replace('-', '_'))(args)
  File "/usr/local/lib/python2.7/dist-packages/pythonforandroid/toolchain.py", line 147, in wrapper_func
    build_dist_from_args(ctx, dist, args)
  File "/usr/local/lib/python2.7/dist-packages/pythonforandroid/toolchain.py", line 169, in build_dist_from_args
    = get_recipe_order_and_bootstrap(ctx, dist.recipes, bs)
  File "/usr/local/lib/python2.7/dist-packages/pythonforandroid/graph.py", line 137, in get_recipe_order_and_bootstrap
    recipe = Recipe.get_recipe(name, ctx)
  File "/usr/local/lib/python2.7/dist-packages/pythonforandroid/recipe.py", line 628, in get_recipe
    recipe = mod.recipe
AttributeError: 'module' object has no attribute 'recipe'

@opacam
Copy link
Member

opacam commented Oct 16, 2016

You have an empty space on the requeriments arguments (between plyer and sqlite3)... besides the sqlite3 dependency should go before the python2. Try with the following requeriments argument:

--requirements=sqlite3,python2,plyer,kivy

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

2 participants