Build failed with error: cannot find symbol

Bitrise Build Issue Report template

Description of the issue

Build failed with error cannot find symbol at import statement

Please describe the issue here
My project has multiple product flavours. (Ex:- flavour1, flavour2, flavour3, flavour4)
I have a Java file(, which are specific to product flavour, so I keep each copy of this file in different flavours source code. But not in main source code folder.
Note: For a given build variant, Gradle throws a build error if it encounters two or more source set directories that have defined the same Java class. For example, when building a debug APK, you cannot define both src/debug/ and src/main/ This is because Gradle looks at both these directories during the build process and throws a ‘duplicate class’ error. If you want different versions of for different build types, you can have each build type define its own version of the file and not include it in the main/ source set.


Where did the issue happen?

If on which stack? If not on on what operating system? (Plus any other information you can share)

Which build Step causes the issue and which version of the step?


  • Does a “Rebuild” help? (You can trigger a rebuild from the Build’s page, by clicking the “Rebuild” button in the top right corner of a finished build) : YES/NO
  • Does a rebuild without caches help? (You can remove the Cache:Pull and Cache:Push steps temporarily to not to use the cache, or you can delete all the caches on the Settings tab of the app. : YES/NO
  • If you have multiple different build configurations (workflows), does the issue affect all/more than one? : YES/NO
  • If it’s an issue which happens sporadically, what’s the frequency? (e.g. Once a day ; about x% of the builds) :
  • Does upgrading the build Step to the latest version help? : YES/NO
  • When did the issue start? :

Linux/Android stack builds

Can it be reproduced by running the build locally, after doing a new git clone of the repository into the /tmp directory and running the build from there with the Bitrise CLI ( )? If no, can it be reproduced with Docker (using the same docker images / environment we use on Related guide: .

Other stacks

Can it be reproduced by running the build locally with our CLI ( ), after doing a new git clone of the repository into the /tmp directory and running the build from there with the Bitrise CLI ( )?

Build log

Please attach the build log (you can download the build log from the build’s page, once the build is finished, using the “Download log” button - floating at the bottom right corner of the log viewer), or if you can’t attach the whole log then send the full log through a private channel (e.g. email - ), with a link to the related GitHub issue.

Can you please include the build’s log or the URL of the build?

Closing as we did not receive the build log yet as far as I know.

@annada if you’d need further assistance please create a new report (can be a copy of this one, or just link this one) but please provide the build log! :slight_smile:

Happy Building! :slight_smile: