openmobilehub / android-omh-auth

Apache License 2.0
4 stars 1 forks source link

Missing dependency `com.openmobilehub.android.auth:plugin-google-gms:2.0.0-beta` and Lack of Build/Publish Instructions #8

Closed dzuluaga closed 8 months ago

dzuluaga commented 9 months ago

The project references the dependency com.openmobilehub.android.auth:plugin-google-gms:2.0.0-beta, but this dependency is not available within the source code. This causes the following build error:

   Failed to resolve: com.openmobilehub.android.auth:plugin-google-gms:2.0.0-beta
   Show in Project Structure dialog
   Affected Modules: auth-sample

Proposed Solutions:

  1. Provide Build and Publish Instructions: Please include a clear and concise guide (e.g., steps in a README file) detailing:
    • How to compile the project.
    • How to use publishToMavenLocal to create a local artifact.

Importance:

Resolving this issue will allow other developers to seamlessly set up the project environment and engage with the code effectively.

Please ensure any other dependencies not included in this bug are also covered as part of the resolution of this bug.

Thanks

dzuluaga commented 8 months ago

@adamTrz - Thank you for advising to use useLocalProjects=true to use local modules instead of Maven Central ones. However, we still need to find a way to avoid this issue for developers unfamiliar with the project, so they don't need to decipher a cryptic error message to resolve this issue. As it stands right now, the sample project will fail until they include useLocalProjects in the local.properties. Is there a way to make Maven Central the default and use local as a fallback? Can you please suggest ideas on how to resolve this issue and improve the developer experience? Thanks.

dzuluaga commented 8 months ago

@adamTrz any news on this? It's been two weeks.

andrei-zgirvaci commented 8 months ago

Hi @dzuluaga, we have made some recent improvements to our contributing.md guide, specifically on how to publish packages to Maven Local and use local modules which we believe makes it easier for developers to get started on contributing to the project.

Regarding your suggestion to prevent developers from encountering the "missing dependency" error. In https://github.com/openmobilehub/android-omh-auth/pull/48/commits/787751b1a5709dd59d11cc7d31195b9016717a5f, I have changed the default setting for useLocalProjects to be true in the gradle.properties file as you suggested, which should solve this and also improve the DX over Maven Local.

Happy to hear your thoughts on this!

cc: @artus9033

dzuluaga commented 8 months ago

Thanks, Andrei, for the update and for making useLocalProjects true by default—this is a great improvement!

Just a quick thought: could we add a brief note in the docs about when to set useLocalProjects to false for using Maven Central dependencies? For example, something like: "Set useLocalProjects to false if you need to ensure your build is using the most recent published versions of dependencies for consistency in CI environments."

This might help clarify the decision process for developers.

Appreciate all the efforts to enhance the DX!

CC - @artus9033 for potential changes in maps. @Nataliagros @kubaluberadzki for triaging, if necessary.