title: Problem making an Android app with BeeWare
body: <p>I tried making an android app with BeeWare following the guides. The app it's just the plain template so I didn't do any modifications to it, but since my first try I was getting countless of exceptions which I was able to resolve looking up for solutions, except this last one that I tried to look up for a fix as I did for the previous one but none of the possible solution I found worked.</p>
  
  <p>I tried launching it from the bash of Visual Code with the Python virtual environment and also with Android Studio, same results...</p>
  
  <p>Console error log:</p>
  
  <pre><code>:transformClassesWithDexBuilderForDebug FAILED
  com.android.builder.dexing.DexArchiveBuilderException: com.android.builder.dexing.DexArchiveBuilderException: Failed to process C:\Java\Visual Basic Code\source\mirror 4.0\ABSOLUTE5\HomeTheater\android\build\intermediates\transforms\desugar\debug\0
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
      at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
      at java.util.concurrent.ForkJoinTask.getThrowableException(ForkJoinTask.java:593)
      at java.util.concurrent.ForkJoinTask.reportException(ForkJoinTask.java:677)
      at java.util.concurrent.ForkJoinTask.join(ForkJoinTask.java:720)
      at com.android.ide.common.internal.WaitableExecutor.waitForTasksWithQuickFail(WaitableExecutor.java:146)
      at com.android.build.gradle.internal.transforms.DexArchiveBuilderTransform.transform(DexArchiveBuilderTransform.java:306)
      at com.android.build.gradle.internal.pipeline.TransformTask$2.call(TransformTask.java:221)
      at com.android.build.gradle.internal.pipeline.TransformTask$2.call(TransformTask.java:217)
      at com.android.builder.profile.ThreadRecorder.record(ThreadRecorder.java:102)
      at com.android.build.gradle.internal.pipeline.TransformTask.transform(TransformTask.java:212)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:498)
      at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:73)
      at org.gradle.api.internal.project.taskfactory.IncrementalTaskAction.doExecute(IncrementalTaskAction.java:50)
      at org.gradle.api.internal.project.taskfactory.StandardTaskAction.execute(StandardTaskAction.java:39)
      at org.gradle.api.internal.project.taskfactory.StandardTaskAction.execute(StandardTaskAction.java:26)
      at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter$1.run(ExecuteActionsTaskExecuter.java:124)
      at org.gradle.internal.operations.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:317)
      at org.gradle.internal.operations.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:309)
      at org.gradle.internal.operations.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:185)
      at org.gradle.internal.operations.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:97)
      at org.gradle.internal.operations.DelegatingBuildOperationExecutor.run(DelegatingBuildOperationExecutor.java:31)
      at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeAction(ExecuteActionsTaskExecuter.java:113)
      at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:95)
      at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:73)
      at org.gradle.api.internal.tasks.execution.OutputDirectoryCreatingTaskExecuter.execute(OutputDirectoryCreatingTaskExecuter.java:51)
      at org.gradle.api.internal.tasks.execution.SkipUpToDateTaskExecuter.execute(SkipUpToDateTaskExecuter.java:59)
      at org.gradle.api.internal.tasks.execution.ResolveTaskOutputCachingStateExecuter.execute(ResolveTaskOutputCachingStateExecuter.java:54)
      at org.gradle.api.internal.tasks.execution.ResolveBuildCacheKeyExecuter.execute(ResolveBuildCacheKeyExecuter.java:66)
      at org.gradle.api.internal.tasks.execution.ValidatingTaskExecuter.execute(ValidatingTaskExecuter.java:59)
      at org.gradle.api.internal.tasks.execution.SkipEmptySourceFilesTaskExecuter.execute(SkipEmptySourceFilesTaskExecuter.java:101)
      at org.gradle.api.internal.tasks.execution.FinalizeInputFilePropertiesTaskExecuter.execute(FinalizeInputFilePropertiesTaskExecuter.java:44)
      at org.gradle.api.internal.tasks.execution.CleanupStaleOutputsExecuter.execute(CleanupStaleOutputsExecuter.java:91)
      at org.gradle.api.internal.tasks.execution.ResolveTaskArtifactStateTaskExecuter.execute(ResolveTaskArtifactStateTaskExecuter.java:62)
      at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:59)
      at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:54)
      at org.gradle.api.internal.tasks.execution.ExecuteAtMostOnceTaskExecuter.execute(ExecuteAtMostOnceTaskExecuter.java:43)
      at org.gradle.api.internal.tasks.execution.CatchExceptionTaskExecuter.execute(CatchExceptionTaskExecuter.java:34)
      at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker$1.run(DefaultTaskGraphExecuter.java:256)
      at org.gradle.internal.operations.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:317)
      at org.gradle.internal.operations.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:309)
      at org.gradle.internal.operations.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:185)
      at org.gradle.internal.operations.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:97)
      at org.gradle.internal.operations.DelegatingBuildOperationExecutor.run(DelegatingBuildOperationExecutor.java:31)
      at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:249)
      at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:238)
      at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker$1.execute(DefaultTaskPlanExecutor.java:104)
      at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker$1.execute(DefaultTaskPlanExecutor.java:98)
      at org.gradle.execution.taskgraph.DefaultTaskExecutionPlan.execute(DefaultTaskExecutionPlan.java:663)
      at org.gradle.execution.taskgraph.DefaultTaskExecutionPlan.executeWithTask(DefaultTaskExecutionPlan.java:596)
      at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker.run(DefaultTaskPlanExecutor.java:98)
      at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:63)
      at org.gradle.internal.concurrent.ManagedExecutorImpl$1.run(ManagedExecutorImpl.java:46)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      at org.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:55)
      at java.lang.Thread.run(Thread.java:748)
  Caused by: com.android.builder.dexing.DexArchiveBuilderException: Failed to process C:\Java\Visual Basic Code\source\mirror 4.0\ABSOLUTE5\HomeTheater\android\build\intermediates\transforms\desugar\debug\0
      at com.android.build.gradle.internal.transforms.DexArchiveBuilderTransform.launchProcessing(DexArchiveBuilderTransform.java:803)
      at com.android.build.gradle.internal.transforms.DexArchiveBuilderTransform.lambda$convertToDexArchive$8(DexArchiveBuilderTransform.java:728)
      at java.util.concurrent.ForkJoinTask$AdaptedCallable.exec(ForkJoinTask.java:1424)
      at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)
      at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056)
      at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692)
      at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:157)
  Caused by: com.android.builder.dexing.DexArchiveBuilderException: Error while dexing.
      at com.android.builder.dexing.D8DexArchiveBuilder.getExceptionToRethrow(D8DexArchiveBuilder.java:169)
      at com.android.builder.dexing.D8DexArchiveBuilder.convert(D8DexArchiveBuilder.java:146)
      at com.android.build.gradle.internal.transforms.DexArchiveBuilderTransform.launchProcessing(DexArchiveBuilderTransform.java:798)
      ... 6 more
  Caused by: java.lang.NullPointerException
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
      at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
      at java.util.concurrent.ForkJoinTask.getThrowableException(ForkJoinTask.java:598)
      at java.util.concurrent.ForkJoinTask.get(ForkJoinTask.java:1005)
      at com.android.tools.r8.utils.ThreadUtils.awaitFutures(ThreadUtils.java:21)
      at com.android.tools.r8.ir.conversion.IRConverter.convertClassesToDex(IRConverter.java:315)
      at com.android.tools.r8.ir.conversion.IRConverter.convertToDex(IRConverter.java:225)
      at com.android.tools.r8.D8.optimize(D8.java:187)
      at com.android.tools.r8.D8.run(D8.java:158)
      at com.android.tools.r8.D8.lambda$run$1(D8.java:91)
      at com.android.tools.r8.utils.ExceptionUtils.withCompilationHandler(ExceptionUtils.java:58)
      at com.android.tools.r8.utils.ExceptionUtils.withD8CompilationHandler(ExceptionUtils.java:45)
      at com.android.tools.r8.D8.run(D8.java:88)
      at com.android.builder.dexing.D8DexArchiveBuilder.convert(D8DexArchiveBuilder.java:144)
      ... 7 more
      Suppressed: java.util.concurrent.ExecutionException: java.lang.NullPointerException
          at java.util.concurrent.ForkJoinTask.get(ForkJoinTask.java:1006)
          ... 17 more
      [CIRCULAR REFERENCE:java.lang.NullPointerException]
  Caused by: java.lang.NullPointerException
      at com.android.tools.r8.ir.conversion.JarState.readLocal(JarState.java:556)
      at com.android.tools.r8.ir.conversion.JarSourceCode.updateState(JarSourceCode.java:1609)
      at com.android.tools.r8.ir.conversion.JarSourceCode.updateState(JarSourceCode.java:1125)
      at com.android.tools.r8.ir.conversion.JarSourceCode.computeBlockEntryJarStates(JarSourceCode.java:442)
      at com.android.tools.r8.ir.conversion.JarSourceCode.buildPrelude(JarSourceCode.java:366)
      at com.android.tools.r8.ir.conversion.IRBuilder.build(IRBuilder.java:362)
      at com.android.tools.r8.graph.JarCode.internalBuild(JarCode.java:149)
      at com.android.tools.r8.graph.JarCode.internalBuildWithLocals(JarCode.java:126)
      at com.android.tools.r8.graph.JarCode.buildIR(JarCode.java:101)
      at com.android.tools.r8.graph.DexEncodedMethod.buildIR(DexEncodedMethod.java:221)
      at com.android.tools.r8.ir.conversion.IRConverter.rewriteCode(IRConverter.java:516)
      at com.android.tools.r8.ir.conversion.IRConverter.convertMethodToDex(IRConverter.java:324)
      at com.android.tools.r8.graph.DexClass.forEachMethodThrowing(DexClass.java:133)
      at com.android.tools.r8.ir.conversion.IRConverter.lambda$convertClassesToDex$2(IRConverter.java:311)
      ... 5 more
  
  </code></pre>
  
  <p>my 'build.gradle'</p>
  
  <pre><code>buildscript {
      repositories {
          jcenter()
          google()
      }
  
      dependencies {
          classpath 'com.android.tools.build:gradle:3.1.1'
      }
  }
  
  task buildPythonDebug &lt;&lt; {
      exec {
          commandLine "voc -v -p app -o build/intermediates/classes/debug app".split()
      }
      exec {
          commandLine "voc -v -p app_packages -o build/intermediates/classes/debug app_packages".split()
      }
  }
  
  task buildPythonRelease &lt;&lt; {
      exec {
          commandLine "voc -v -p app -o build/intermediates/classes/release app".split()
      }
      exec {
          commandLine "voc -v -p app_packages -o build/intermediates/classes/release app_packages".split()
      }
  }
  
  task run &lt;&lt; {
      exec {
          commandLine "adb shell am start -n com.homesmart.HomeTheater/android.Saibbo".split()
      }
  }
  
  apply plugin: 'com.android.application'
  
  android {
      compileSdkVersion 27
      buildToolsVersion '27.0.3'
  
      defaultConfig {
          minSdkVersion 15
          targetSdkVersion 27
          versionCode 1
          versionName "1.0"
          multiDexEnabled true
      }
      sourceSets {
          main {
              manifest.srcFile 'AndroidManifest.xml'
              java.srcDirs = ['src']
              res.srcDirs = ['res']
          }
      }
      compileOptions {
          sourceCompatibility = '1.8'
          targetCompatibility = '1.8'
      }
  }
  
  project.afterEvaluate {
      packageDebug.dependsOn buildPythonDebug
      packageRelease.dependsOn buildPythonRelease
      run.dependsOn installDebug
  }
  
  dependencies {
      implementation fileTree(include: ['*.jar'], dir: 'libs')
      implementation 'com.android.support:appcompat-v7:25.1.1'
  }
  
  repositories {
      google()
  }
  </code></pre>
  
  <p>more details</p>
  
  <pre><code>com.android.build.api.transform.TransformException: com.android.builder.dexing.DexArchiveBuilderException: com.android.builder.dexing.DexArchiveBuilderException: Failed to process C:\Java\Visual Basic Code\source\mirror 4.0\ABSOLUTE5\HomeTheater\android\build\intermediates\transforms\desugar\debug\0
  &gt; com.android.builder.dexing.DexArchiveBuilderException: com.android.builder.dexing.DexArchiveBuilderException: Failed to process C:\Java\Visual Basic Code\source\mirror 4.0\ABSOLUTE5\HomeTheater\android\build\intermediates\transforms\desugar\debug\0
    &gt; com.android.builder.dexing.DexArchiveBuilderException: Failed to process C:\Java\Visual Basic Code\source\mirror 4.0\ABSOLUTE5\HomeTheater\android\build\intermediates\transforms\desugar\debug\0
      &gt; Failed to process C:\Java\Visual Basic Code\source\mirror 4.0\ABSOLUTE5\HomeTheater\android\build\intermediates\transforms\desugar\debug\0
        &gt; Error while dexing.
          &gt; (No message provided)
            &gt; (No message provided)
  
  
  
  
  
  
  org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':transformClassesWithDexBuilderForDebug'.Open stacktrace
  Caused by: java.lang.RuntimeException: com.android.build.api.transform.TransformException: com.android.builder.dexing.DexArchiveBuilderException: com.android.builder.dexing.DexArchiveBuilderException: Failed to process C:\Java\Visual Basic Code\source\mirror 4.0\ABSOLUTE5\HomeTheater\android\build\intermediates\transforms\desugar\debug\0Open stacktrace
  Caused by: com.android.build.api.transform.TransformException: com.android.builder.dexing.DexArchiveBuilderException: com.android.builder.dexing.DexArchiveBuilderException: Failed to process C:\Java\Visual Basic Code\source\mirror 4.0\ABSOLUTE5\HomeTheater\android\build\intermediates\transforms\desugar\debug\0Open stacktrace
  Caused by: com.android.builder.dexing.DexArchiveBuilderException: com.android.builder.dexing.DexArchiveBuilderException: Failed to process C:\Java\Visual Basic Code\source\mirror 4.0\ABSOLUTE5\HomeTheater\android\build\intermediates\transforms\desugar\debug\0Open stacktrace
  Caused by: com.android.builder.dexing.DexArchiveBuilderException: Failed to process C:\Java\Visual Basic Code\source\mirror 4.0\ABSOLUTE5\HomeTheater\android\build\intermediates\transforms\desugar\debug\0Open stacktrace
  Caused by: com.android.builder.dexing.DexArchiveBuilderException: Error while dexing.Open stacktrace
  Caused by: java.lang.NullPointerException: (No message provided)Open stacktrace
  Caused by: java.lang.NullPointerException: (No message provided)Close stacktrace
  at com.android.tools.r8.ir.conversion.JarState.readLocal(JarState.java:556)
  at com.android.tools.r8.ir.conversion.JarSourceCode.updateState(JarSourceCode.java:1609)
  at com.android.tools.r8.ir.conversion.JarSourceCode.updateState(JarSourceCode.java:1125)
  at com.android.tools.r8.ir.conversion.JarSourceCode.computeBlockEntryJarStates(JarSourceCode.java:442)
  at com.android.tools.r8.ir.conversion.JarSourceCode.buildPrelude(JarSourceCode.java:366)
  at com.android.tools.r8.ir.conversion.IRBuilder.build(IRBuilder.java:362)
  at com.android.tools.r8.graph.JarCode.internalBuild(JarCode.java:149)
  at com.android.tools.r8.graph.JarCode.internalBuildWithLocals(JarCode.java:126)
  at com.android.tools.r8.graph.JarCode.buildIR(JarCode.java:101)
  at com.android.tools.r8.graph.DexEncodedMethod.buildIR(DexEncodedMethod.java:221)
  at com.android.tools.r8.ir.conversion.IRConverter.rewriteCode(IRConverter.java:516)
  at com.android.tools.r8.ir.conversion.IRConverter.convertMethodToDex(IRConverter.java:324)
  at com.android.tools.r8.graph.DexClass.forEachMethodThrowing(DexClass.java:133)
  at com.android.tools.r8.ir.conversion.IRConverter.lambda$convertClassesToDex$2(IRConverter.java:311)
  </code></pre>
  
  <blockquote>
    <p>Gradle 4.7, Build scan plugin 1.13, Android Gradle plugin 3.1.1</p>
  </blockquote>