shashi278 / social-auth-kivy

Integrate Google, Facebook, Github & Twitter login in kivy applications
MIT License
150 stars 23 forks source link

error on android.gradle_dependencies = com.google.android.gms:play-services-auth:18.0.0 #14

Closed 1357koushik closed 3 years ago

1357koushik commented 3 years ago

File "/data/user/0/ru.iiec.pydroid3/files/aarch64-linux-android/lib/python3.8/site-packages/kivyauth/google_auth.py", line 6, in Gso = autoclass("com.google.android.gms.auth.api.signin.GoogleSignInOptions") File "/data/user/0/ru.iiec.pydroid3/files/aarch64-linux-android/lib/python3.8/site-packages/jnius/reflect.py", line 208, in autoclass c = find_javaclass(clsname) File "jnius/jnius_export_func.pxi", line 28, in jnius.jnius.find_javaclass jnius.jnius.JavaException: Class not found b'com/google/android/gms/auth/api/signin/GoogleSignInOptions' i tried in pydroid3

shashi278 commented 3 years ago

It should not work on pydroid3 because it requires different libs(aar, jar, etc.)

1357koushik commented 3 years ago

It should not work on pydroid3 because it requires different libs(aar, jar, etc.)

ok i got buildozer error then i add android.gradle_dependencies = com.google.android.gms:play-services-auth:18.0.0 log i got it `* What went wrong: Execution failed for task ':processDebugResources'.

Failed to process resources, see aapt output above for details.

Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0. Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/6.4.1/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 1s
13 actionable tasks: 2 executed, 11 up-to-date

<-------------> 0% WAITING> IDLE> IDLE

cd /content/.buildozer/android/platform/build-armeabi-v7a/dists/apparmeabi-v7a && /content/.buildozer/android/platform/build-armeabi-v7a/dists/apparmeabi-v7a/gradlew assembleDebug

[WARNING]: ERROR: /content/.buildozer/android/platform/build-armeabi-v7a/dists/app__armeabi-v7a/gradlew failed! WARNING: Received a --sdk argument, but this argument is deprecated and does nothing. No setup.py/pyproject.toml used, copying full private data into .apk. Applying Java source code patches... Applying patch: src/patches/SDLActivity.java.patch Warning: failed to apply patch (exit code 1), assuming it is already applied: src/patches/SDLActivity.java.patch

Command failed: /usr/bin/python3 -m pythonforandroid.toolchain apk --debug --bootstrap=sdl2 --dist_name app --name Pixel --version 0.1 --package tk.pixelteams.app --minsdk 21 --ndk-api 21 --private /content/.buildozer/android/app --permission INTERNET --android-entrypoint org.kivy.android.PythonActivity --android-apptheme @android:style/Theme.NoTitleBar --orientation portrait --window --copy-libs --depend com.google.android.gms:play-services-auth:18.0.0 --arch armeabi-v7a --color=always --storage-dir="/content/.buildozer/android/platform/build-armeabi-v7a" --ndk-api=21

ENVIRONMENT:

CUDNN_VERSION = '8.0.4.30'

PYDEVD_USE_FRAME_EVAL = 'NO'

LD_LIBRARY_PATH = '/usr/local/nvidia/lib:/usr/local/nvidia/lib64'

CLOUDSDK_PYTHON = 'python3'

LANG = 'en_US.UTF-8'

HOSTNAME = '8c3230defb1d'

OLDPWD = '/'

CLOUDSDK_CONFIG = '/content/.config'

NVIDIA_VISIBLE_DEVICES = 'all'

DATALAB_SETTINGS_OVERRIDES = '{"kernelManagerProxyPort":6000,"kernelManagerProxyHost":"172.28.0.3","jupyterArgs":["--ip=\"172.28.0.2\""],"debugAdapterMultiplexerPath":"/usr/local/bin/dap_multiplexer"}'

ENV = '/root/.bashrc'

PAGER = 'cat'

NCCL_VERSION = '2.7.8'

TF_FORCE_GPU_ALLOW_GROWTH = 'true'

JPY_PARENT_PID = '46'

NO_GCE_CHECK = 'True'

PWD = '/content'

HOME = '/root'

LAST_FORCED_REBUILD = '20210504'

CLICOLOR = '1'

DEBIAN_FRONTEND = 'noninteractive'

LIBRARY_PATH = '/usr/local/cuda/lib64/stubs'

GCE_METADATA_TIMEOUT = '0'

GLIBCPP_FORCE_NEW = '1'

TBE_CREDS_ADDR = '172.28.0.1:8008'

TERM = 'xterm-color'

SHELL = '/bin/bash'

GCS_READ_CACHE_BLOCK_SIZE_MB = '16'

PYTHONWARNINGS = 'ignore:::pip._internal.cli.base_command'

MPLBACKEND = 'module://ipykernel.pylab.backend_inline'

CUDA_VERSION = '11.0.3'

NVIDIA_DRIVER_CAPABILITIES = 'compute,utility'

SHLVL = '1'

PYTHONPATH = '/env/python'

NVIDIA_REQUIRE_CUDA = ('cuda>=11.0 brand=tesla,driver>=418,driver<419 '

'brand=tesla,driver>=440,driver<441 brand=tesla,driver>=450,driver<451')

COLAB_GPU = '0'

GLIBCXX_FORCE_NEW = '1'

PATH = '/root/.buildozer/android/platform/apache-ant-1.9.4/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/tools/node/bin:/tools/google-cloud-sdk/bin:/opt/bin'

LD_PRELOAD = '/usr/lib/x86_64-linux-gnu/libtcmalloc.so.4'

GIT_PAGER = 'cat'

_ = '/usr/local/bin/buildozer'

PACKAGES_PATH = '/root/.buildozer/android/packages'

ANDROIDSDK = '/root/.buildozer/android/platform/android-sdk'

ANDROIDNDK = '/root/.buildozer/android/platform/android-ndk-r19c'

ANDROIDAPI = '27'

ANDROIDMINAPI = '21'

Buildozer failed to execute the last command`

because then i remove android.gradle_dependencies = com.google.android.gms:play-services-auth:18.0.0 its working good

shashi278 commented 3 years ago

Hi @1357koushik, I'm assuming it to be something related to the API level. There should be more gradle output above

Execution failed for task ':processDebugResources'.

which might be helpful in this case.

1357koushik commented 3 years ago

Hi @1357koushik, I'm assuming it to be something related to the API level. There should be more gradle output above

Execution failed for task ':processDebugResources'.

which might be helpful in this case.

HERE is the full log I think Listing '/content/.buildozer/android/platform/build-armeabi-v7a/dists/myapparmeabi-v7a/_python_bundle/_python_bundle/site-packages/setuptools'... Listing '/content/.buildozer/android/platform/build-armeabi-v7a/dists/myapparmeabi-v7a/_python_bundle/_python_bundle/site-packages/setuptools/_vendor'... Listing '/content/.buildozer/android/platform/build-armeabi-v7a/dists/myapp__armeabi-v7a/_python_bundle/_python_bundle/site-packages/setuptools/_vendor/packaging'... Listing '/content/.buildozer/android/platform/build-armeabi-v7a/dists/myapparmeabi-v7a/_python_bundle/_python_bundle/site-packages/setuptools/command'... Listing '/content/.buildozer/android/platform/build-armeabi-v7a/dists/myapparmeabi-v7a/_python_bundle/_python_bundle/site-packages/setuptools/extern'... Listing '/content/.buildozer/android/platform/build-armeabi-v7a/dists/myapparmeabi-v7a/_python_bundle/_python_bundle/site-packages/setuptools-40.9.0-py3.8.egg-info'... Listing '/content/.buildozer/android/platform/build-armeabi-v7a/dists/myapparmeabi-v7a/_python_bundle/_python_bundle/site-packages/usr'... Listing '/content/.buildozer/android/platform/build-armeabi-v7a/dists/myapparmeabi-v7a/_python_bundle/_python_bundle/site-packages/usr/local'... Listing '/content/.buildozer/android/platform/build-armeabi-v7a/dists/myapparmeabi-v7a/_python_bundle/_python_bundle/site-packages/usr/local/bin'... INFO: Detected highest available build tools version to be 31.0.0-rc3 [DEBUG]: -> running gradlew assembleDebug [DEBUG]:
[DEBUG]:
[DEBUG]: > Connecting to Daemon<-------------> 0% CONFIGURING [53ms]> root project > Resolve dependencies of :classpath<-------------> 0% CONFIGURING [149ms]> root project > Resolve files of :classpath<-------------> 0% CONFIGURING [249ms]> root project [DEBUG]: > Configure project : [DEBUG]: WARNING: Configuration 'compile' is obsolete and has been replaced with 'implementation' and 'api'. [DEBUG]: It will be removed at the end of 2018. For more information see: http://d.android.com/r/tools/update-dependency-configurations.html [DEBUG]:
[DEBUG]:
[DEBUG]: <-------------> 2% EXECUTING [349ms]> :preDebugBuild > Resolve dependencies of :debugCompileClasspath<-------------> 2% EXECUTING [449ms]> :preDebugBuild > Resolve files of :debugCompileClasspath > Transform artifact [DEBUG]: <-------------> 5% EXECUTING [549ms]> :compileDebugAidl > Resolve files of :debugCompileClasspath > Transform artif> :compileDebugAidl > Resolve files of :debugCompileClasspath > Transform artif<=------------> 8% EXECUTING [649ms]> :compileDebugRenderscript > Resolve files of :debugCompileClasspath > Transfo> :compileDebugRenderscript > Resolve files of :debugCompileClasspath > Transfo<===----------> 28% EXECUTING [749ms]> :mergeDebugResources> IDLE<===----------> 28% EXECUTING [849ms]<===----------> 28% EXECUTING [949ms]<===----------> 28% EXECUTING [1s]<====---------> 34% EXECUTING [1s]> :processDebugManifest<====---------> 37% EXECUTING [1s]> :splitsDiscoveryTaskDebug<=====--------> 40% EXECUTING [1s]> :processDebugResources/root/.gradle/caches/transforms-2/files-2.1/660d392c0db455ede653ba6d4ca9a28a/res/values/values.xml:133:5-70: AAPT: error: resource android:attr/fontVariationSettings not found. [DEBUG]:
[DEBUG]: /root/.gradle/caches/transforms-2/files-2.1/660d392c0db455ede653ba6d4ca9a28a/res/values/values.xml:133:5-70: AAPT: error: resource android:attr/ttcIndex not found. [DEBUG]:
[DEBUG]: error: failed linking references. [DEBUG]:
[DEBUG]:
[DEBUG]:
[DEBUG]: <=====--------> 40% EXECUTING [1s]> :processDebugResources> IDLE [DEBUG]: > Task :processDebugResources FAILED [DEBUG]:
[DEBUG]: FAILURE: Build failed with an exception. [DEBUG]:
[DEBUG]: What went wrong: [DEBUG]: Execution failed for task ':processDebugResources'. [DEBUG]: > Failed to process resources, see aapt output above for details. [DEBUG]:
[DEBUG]:
Try: [DEBUG]: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. [DEBUG]:
[DEBUG]: Get more help at https://help.gradle.org [DEBUG]:
[DEBUG]: Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0. [DEBUG]: Use '--warning-mode all' to show the individual deprecation warnings. [DEBUG]: See https://docs.gradle.org/6.4.1/userguide/command_line_interface.html#sec:command_line_warnings [DEBUG]:
[DEBUG]: BUILD FAILED in 3s [DEBUG]: 13 actionable tasks: 13 executed [DEBUG]:
[DEBUG]:
[DEBUG]:
Exception in thread background thread for pid 45984: Traceback (most recent call last): File "/usr/lib/python3.7/threading.py", line 926, in _bootstrap_inner self.run() File "/usr/lib/python3.7/threading.py", line 870, in run self._target(
self._args, *self._kwargs) File "/usr/local/lib/python3.7/dist-packages/sh.py", line 1683, in wrap fn(rgs, **kwargs) File "/usr/local/lib/python3.7/dist-packages/sh.py", line 2662, in background_thread handle_exit_code(exit_code) File "/usr/local/lib/python3.7/dist-packages/sh.py", line 2349, in fn return self.command.handle_command_exit_code(exit_code) File "/usr/local/lib/python3.7/dist-packages/sh.py", line 905, in handle_command_exit_code raise exc sh.ErrorReturnCode_1:

RAN: /content/.buildozer/android/platform/build-armeabi-v7a/dists/myapp__armeabi-v7a/gradlew assembleDebug

STDOUT:

Connecting to Daemon<-------------> 0% CONFIGURING [53ms]> root project > Resolve dependencies of :classpath<-------------> 0% CONFIGURING [149ms]> root project > Resolve files of :classpath<-------------> 0% CONFIGURING [249ms]> root project Configure project : WARNING: Configuration 'compile' is obsolete and has been replaced with 'implementation' and 'api'. It will be removed at the end of 2018. For more information see: http://d.android.com/r/tools/update-dependency-configurations.html

<-------------> 2% EXECUTING [349ms]> :preDebugBuild > Resolve dependencies of :debugCompileClasspath<-------------> 2% EXECUTING [449ms]> :preDebugBuild > Resolve files of :debugCompileClasspath > Transform artifact <-------------> 5% EXECUTING [549ms]> :compileDebugAidl > Resolve files of :debugCompileClasspath > Transform artif> :compileDebugAidl > Resolve files of :debugCompileClasspath > Transform artif<=------------> 8% EXECUTING [649ms]> :compileDebugRenderscript > Resolve files of :debugCompileClasspath > Transfo> :compileDebugRenderscript > Resolve files of :debugCompileClasspath > Transfo<===----------> 28% EXECUTING [749ms]> :mergeDebugResources> IDLE<===----------> 28% EXECUTING [849ms]<===----------> 28% EXECUTING [949ms]<===----------> 28% EXECUTING [1s]<====---------> 34% EXECUTING [1s]> :processDebugManifest<====---------> 37% EXECUTING [1s]> :splitsDiscoveryTaskDebug<=====--------> 40% EXECUTING [1s]> :processDebugResources/root/.gradle/caches/transforms-2/files-2.1/660d392c0db455ede653ba6d4ca9a28a/res/values/values.xml:133:5-70: AAPT: error: resource android:attr/fontVariationSettings not found.

/root/.gradle/caches/transforms-2/files-2.1/660d392c0db455ede653ba6d4ca9a28a/res/values/values.xml:133:5-70: AAPT: error: resource android:attr/ttcIndex not found.

error: failed linking references.

<=====--------> 40% EXECUTING [1s]> :processDebugResources> IDLE

Task :processDebugResources FAILED

FAILURE: Build failed with an exception.

Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0. Use '--warning-mode all' to show the individual deprecation warnings. See https://docs.gradle.org/6.4.1/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 3s 13 actionable tasks: 13 executed

STDERR:

[DEBUG]: <-------------> 0% WAITING> IDLE> IDLE INFO: STDOUT (last 20 lines of 41):

Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0. Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/6.4.1/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 3s
13 actionable tasks: 13 executed

<-------------> 0% WAITING> IDLE> IDLE

cd /content/.buildozer/android/platform/build-armeabi-v7a/dists/myapparmeabi-v7a && /content/.buildozer/android/platform/build-armeabi-v7a/dists/myapparmeabi-v7a/gradlew assembleDebug

[WARNING]: ERROR: /content/.buildozer/android/platform/build-armeabi-v7a/dists/myapp__armeabi-v7a/gradlew failed! WARNING: Received a --sdk argument, but this argument is deprecated and does nothing. No setup.py/pyproject.toml used, copying full private data into .apk. Applying Java source code patches... Applying patch: src/patches/SDLActivity.java.patch Command failed: /usr/bin/python3 -m pythonforandroid.toolchain apk --debug --bootstrap=sdl2 --dist_name myapp --name 'My Application' --version 0.1 --package org.test.myapp --minsdk 21 --ndk-api 21 --private /content/.buildozer/android/app --android-entrypoint org.kivy.android.PythonActivity --android-apptheme @android:style/Theme.NoTitleBar --orientation portrait --window --copy-libs --depend com.google.android.gms:play-services-auth:18.0.0 --arch armeabi-v7a --color=always --storage-dir="/content/.buildozer/android/platform/build-armeabi-v7a" --ndk-api=21 ENVIRONMENT: CUDNN_VERSION = '8.0.4.30' PYDEVD_USE_FRAME_EVAL = 'NO' LD_LIBRARY_PATH = '/usr/local/nvidia/lib:/usr/local/nvidia/lib64' CLOUDSDK_PYTHON = 'python3' LANG = 'en_US.UTF-8' HOSTNAME = '4ce3add19d5e' OLDPWD = '/' CLOUDSDK_CONFIG = '/content/.config' NVIDIA_VISIBLE_DEVICES = 'all' DATALAB_SETTINGS_OVERRIDES = '{"kernelManagerProxyPort":6000,"kernelManagerProxyHost":"172.28.0.3","jupyterArgs":["--ip=\"172.28.0.2\""],"debugAdapterMultiplexerPath":"/usr/local/bin/dap_multiplexer"}' ENV = '/root/.bashrc' PAGER = 'cat' NCCL_VERSION = '2.7.8' TF_FORCE_GPU_ALLOW_GROWTH = 'true' JPY_PARENT_PID = '47' NO_GCE_CHECK = 'True' PWD = '/content' HOME = '/root' LAST_FORCED_REBUILD = '20210504' CLICOLOR = '1' DEBIAN_FRONTEND = 'noninteractive' LIBRARY_PATH = '/usr/local/cuda/lib64/stubs' GCE_METADATA_TIMEOUT = '0' GLIBCPP_FORCE_NEW = '1' TBE_CREDS_ADDR = '172.28.0.1:8008' TERM = 'xterm-color' SHELL = '/bin/bash' GCS_READ_CACHE_BLOCK_SIZE_MB = '16' PYTHONWARNINGS = 'ignore:::pip._internal.cli.base_command' MPLBACKEND = 'module://ipykernel.pylab.backend_inline' CUDA_VERSION = '11.0.3' NVIDIA_DRIVER_CAPABILITIES = 'compute,utility' SHLVL = '1' PYTHONPATH = '/env/python' NVIDIA_REQUIRE_CUDA = ('cuda>=11.0 brand=tesla,driver>=418,driver<419 ' 'brand=tesla,driver>=440,driver<441 brand=tesla,driver>=450,driver<451') COLAB_GPU = '0' GLIBCXX_FORCE_NEW = '1' PATH = '/root/.buildozer/android/platform/apache-ant-1.9.4/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/tools/node/bin:/tools/google-cloud-sdk/bin:/opt/bin' LD_PRELOAD = '/usr/lib/x86_64-linux-gnu/libtcmalloc.so.4' GITPAGER = 'cat' = '/usr/local/bin/buildozer' PACKAGES_PATH = '/root/.buildozer/android/packages' ANDROIDSDK = '/root/.buildozer/android/platform/android-sdk' ANDROIDNDK = '/root/.buildozer/android/platform/android-ndk-r19c' ANDROIDAPI = '27' ANDROIDMINAPI = '21'

Buildozer failed to execute the last command The error might be hidden in the log above this error Please read the full log, and search for it before raising an issue with buildozer itself. In case of a bug report, please add a full log with log_level = 2

shashi278 commented 3 years ago

Just as I suspected. fontVariationSettings has been added in api level 28 so you need to change the api level to 28 or above in your buildozer.spec file.

1357koushik commented 3 years ago

Just as I suspected. fontVariationSettings has been added in api level 28 so you need to change the api level to 28 or above in your buildozer.spec file.

i changed android.api = 28 but getting same

shashi278 commented 3 years ago

Kinda strange. Could you try it with 29? If still doesn't work then try cleaning before next build.

1357koushik commented 3 years ago

Kinda strange. Could you try it with 29? If still doesn't work then try cleaning before next build.

😊 thanks this solved I think you have to change prerequisites.md

shashi278 commented 3 years ago

@1357koushik glad it worked! Yeah I need to update Readme. Would you like to confirm what worked for you, 28 or 29?

1357koushik commented 3 years ago

@1357koushik glad it worked! Yeah I need to update Readme. Would you like to confirm what worked for you, 28 or 29?

29 worked 👍