Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ditch mavenLocal #387

Open
jamesward opened this issue May 8, 2023 · 4 comments
Open

Ditch mavenLocal #387

jamesward opened this issue May 8, 2023 · 4 comments
Assignees

Comments

@jamesward
Copy link
Collaborator

Currently grpc-kotlin's CI publishes to the Maven Local repo, then the samples use that repo to verify that everything works. But it turns out that using mavenLocal() has a bunch of bad side effects. For example, if a dependency is pulled into Maven Local via Maven, then it doesn't have the Gradle metadata and that can cause differing dependency resolution. So this project should ditch Maven Local to support more deterministic builds.

@jamesward jamesward self-assigned this May 8, 2023
@bubenheimer
Copy link

Will I still be able to do 'publishToMavenLocal' myself, though? That's an easy standard Gradle thing an outside contributor can use to build and use artifacts locally for testing PRs, etc. I just tried to build a major Android-related project that somehow disabled 'publishToMavenLocal', and at some point I just had to give up, it was a big waste of time and certainly did not increase my appreciation levels for said project.

@jamesward
Copy link
Collaborator Author

This shouldn't impact you. We just won't use mavenLocal() in the examples project. Curious for more details on why you are using publishToMavenLocal though.

@bubenheimer
Copy link

Generally speaking I like using publishToMavenLocal when I want to test a PR or other change to a 3rd party project. That way I can easily try out the changed artifacts in my own projects locally to see if the change works as I expected.

Is there a better way? Straightforward alternatives I can think of: running my own proper repo locally (too much maintenance), copying build artifacts over to my project (dependencies are lost), publishing to public repo with changed coordinates (have to change some stuff around in 3rd party project and my own), maybe build via GitHub (no experience there). The other project I mentioned recommended using direct project() dependencies, but that requires my project's build setup to be compatible with theirs.

@jamesward
Copy link
Collaborator Author

I'm currently exploring using Gradle Composite builds as a way to handle this scenario:
https://docs.gradle.org/current/userguide/composite_builds.html

But I haven't yet tested this approach with grpc-kotlin.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants