gotev / android-upload-service

Easily upload files (Multipart/Binary/FTP out of the box) in the background with progress notification. Support for persistent upload requests, customizations and custom plugins.
Apache License 2.0
2.83k stars 692 forks source link

Bitrise CI Build Failing with New Version #656

Closed sayantanLudimos closed 8 months ago

sayantanLudimos commented 8 months ago

Describe the bug Bitrise CI Build failing with the new version of the library but working fine for the version 'net.gotev:uploadservice:4.7.0'

To Reproduce Steps to reproduce the behavior:

  1. Push the code to a branch
  2. Bitrise will start automated building
  3. Build failed after few time.
  4. See error

Expected behavior Build should not be failed for the library.

Debug Log:

Task :app:kaptLudimosReleaseKotlin /bitrise/src/app/build/tmp/kapt3/stubs/[REDACTED]Release/com/[REDACTED]app/presentation/ui/uploadvideoai/uploaddetails/PendingUploadsFragment.java:61: error: cannot access UploadInfo private final int getTimeRemaining(net.gotev.uploadservice.data.UploadInfo uploadInfo) { ^ bad class file: /root/.gradle/caches/transforms-3/05ed049cbeb6603da12042d7fb163bed/transformed/jetified-uploadservice-4.9.2-api.jar(/net/gotev/uploadservice/data/UploadInfo.class) class file has wrong version 61.0, should be 55.0 Please remove or make sure it appears in the correct subdirectory of the classpath. /bitrise/src/app/build/tmp/kapt3/stubs/[REDACTED]Release/com/[REDACTED]app/presentation/utils/videouploadmodule/VideoUploadManager.java:10: error: cannot access RequestObserverDelegate private final net.gotev.uploadservice.observer.request.RequestObserverDelegate delegate = null; ^ bad class file: /root/.gradle/caches/transforms-3/05ed049cbeb6603da12042d7fb163bed/transformed/jetified-uploadservice-4.9.2-api.jar(/net/gotev/uploadservice/observer/request/RequestObserverDelegate.class) class file has wrong version 61.0, should be 55.0 Please remove or make sure it appears in the correct subdirectory of the classpath. /bitrise/src/app/build/tmp/kapt3/stubs/[REDACTED]Release/com/[REDACTED]app/presentation/foundation/workmanager/SingleNotificationHandler.java:6: error: cannot access AbstractSingleNotificationHandler public final class SingleNotificationHandler extends net.gotev.uploadservice.observer.task.AbstractSingleNotificationHandler { ^ bad class file: /root/.gradle/caches/transforms-3/05ed049cbeb6603da12042d7fb163bed/transformed/jetified-uploadservice-4.9.2-api.jar(/net/gotev/uploadservice/observer/task/AbstractSingleNotificationHandler.class) class file has wrong version 61.0, should be 55.0 Please remove or make sure it appears in the correct subdirectory of the classpath. /bitrise/src/app/build/tmp/kapt3/stubs/[REDACTED]Release/com/[REDACTED]app/presentation/foundation/workmanager/SingleNotificationHandler.java:9: error: cannot access UploadService net.gotev.uploadservice.UploadService service) { ^ bad class file: /root/.gradle/caches/transforms-3/05ed049cbeb6603da12042d7fb163bed/transformed/jetified-uploadservice-4.9.2-api.jar(/net/gotev/uploadservice/UploadService.class) class file has wrong version 61.0, should be 55.0 Please remove or make sure it appears in the correct subdirectory of the classpath.

Task :app:kaptLudimosReleaseKotlin FAILED

FAILURE: Build failed with an exception.

gotev commented 8 months ago

You need to change Java version from 11 to at least 17 in your Bitrise CI pipeline. Java 17+ is mandatory to support API 33+ targets. I had to do the same on my GitHub Actions pipelines.