Unable to build pipeline due to missing file and plugin issue
Asked by scrollbart:

Could someone help me with this error? I'm building an Android project with the default Android pipelines yml on a existing project and I am getting this error. When creating a new project everything seems to work, but this existing project is keep giving me this error.


Answers:
author: Vijith Menon
body: We got the same error, it was due to a [plugin](https://github.com/google/secrets-gradle-plugin) we added.

```
'com.google.android.libraries.mapsplatform.secrets-gradle-plugin'
```

![screenshot (1).png](https://community.atlassian.com/t5/image/serverpage/image-id/188955iB5BE6C7C6A3A2615/image-size/large?v=v2&px=999 "screenshot (1).png")  

We weren't really using it, so removing it fixed the issue for us.

comments: author: Dimitris Kotronis
body: Same here, I was not using the lib yes and removing it solved the problem. However in case someone wants to use the plugin I am not sure how it's done.


author: Oluwasegun Ilori
body: I have this issue and I need to use the library


author: Akhunzaada
body: To fix the issue with *secrets-gradle-plugin* , simply add a *local.defaults.properties* file to your source control with all the keys assigned with safe default values. Configure the created file in your module's gradle file as:

```
secrets {    defaultPropertiesFileName = 'local.defaults.properties'}
```

Please refer to the [*documentation*](https://github.com/google/secrets-gradle-plugin#cicd-systems) for more.


author: scrollbart
body: Hey Norbert,

The file is indeed not there (also not in the project that is working though). Doesn't bitbucket add this directory when cloning it itself (so it makes sense it's not there in my local project)?

Cheers,

Bart

comments: author: Norbert C
body: Hi Bart,

Thank you for your reply.  

Basically how Pipeline works is that it clones the content of your repository in the "/opt/atlassian/pipelines/agent/build" directory.

Can you let me know whether if the "local.properties" file is there in your repository's root directory?

Best Regards,  
Norbert  
Atlassian Bitbucket Cloud Support


author: scrollbart
body: Hi Norbert,

Yes the file is there (in both the working project and the not working)


author: scrollbart
body: Hi [@Norbert C](/t5/user/viewprofilepage/user-id/1190200) ,

Do you have any idea what else I can try?

Cheers,

Bart


author: Norbert C
body: Hi [@scrollbart](/t5/user/viewprofilepage/user-id/4798847)

Please excuse me for the late reply. Unfortunately I'm not really familiar with building Android projects with Pipelines. Can you try to debug this issue locally using Docker as it's mentioned in [this documentation?](https://support.atlassian.com/bitbucket-cloud/docs/debug-pipelines-locally-with-docker/)

This way we can verify whether if this is a Bitbucket Pipelines or a build issue.

Also would it be possible for you to try [@Vijith Menon](/t5/user/viewprofilepage/user-id/4800284)suggestion? Does Vijith's workaround works for you?

Please let me know.

Best Regards,  
Norbert  
Atlassian Bitbucket Cloud Support


author: Norbert C
body: Hi [@scrollbart](/t5/user/viewprofilepage/user-id/4798847)

Thank you for contacting Atlassian Community, my name is Norbert and I'm a Bitbucket Cloud Support Engineer, it's nice to meet with you! Welcome to the Atlassian Community!

Based on the error message, the "/opt/atlassian/pipelines/agent/build/local.properties" file can't be found, once you're trying to do the build.

To verify if the file is there or not, can you run the following command and give me the output?

```
ls -lthra /opt/atlassian/pipelines/agent/build/local.properties
```

I'm looking forward to hear from you.

Best Regards,  
Norbert  
Atlassian Bitbucket Cloud Support


Tags: android

atl-orange

bitbucket-cloud

cloud