-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
incorrect <name> entry in pom ("core" instead of "cats-core") #1396
Comments
My understanding was that |
Full Pom ref. First import point is that a Maven POM "contains all necessary information about a project, as well as configurations of plugins to be used during the build process". ie it is more like a And:
So name, I believe, should be the sbt project name, eg "core", by default and the artifactId used instead. (So can be used to know "what sbt project do have to override to..."). Downside is that the artifactId also includes scala version, but that is in fact an sbt convention with standard semantics. |
So, I posted within 24 seconds of @travisbrown. Snap - I lose 😄 |
@BennyHill But you had the citation and I didn't, so let's call it a tie. :) |
I don't know this relates to Dbuild, but as @travisbrown and @BennyHill noted the name part is for human consumption, so you can put |
There is a difference between |
Sounds like a bug in dbuild to me. Nonetheless I personally wouldn't name an artefact at org.typelevel / cats-core_2.11 simply "core". Also, btw, here's some more tooling interaction around project id, name and moduleName: #203 (comment) |
just for the record, I realized I should diffed the POMs to be sure that
but I see from the POM Reference that Alistair linked to that |
sbt defaults description to name: https://github.com/sbt/sbt/blob/v0.13.12/main/src/main/scala/sbt/Defaults.scala#L1142 |
So ideally, say for cats core, we could have : <name>Cats Core Module</name>
<description>The cats core module contains most core type classes and functionality. This module is required).</description> Note my deliberately confusing use of |
Yes, I verified that in dbuild, where this particulat duplicate checking occurs, the name is checked instead of the moduleName. The data, however, percolates from afar; I need to track backwards where the incorrect value originates from. It may take a while until I debug the whole thing. |
ok. so from the Cats side, the pom isn't actually incorrect, but it could probably stand some improvement, regardless. not sure whether y'all want to leave the ticket open — it would be reasonable to just close it, and there could be a separate "improve human-readability of metadata in Cats poms" ticket. (thanks, Dale, btw, for finding #203, very helpful) in the community build, I can work around this. @cunei thanks — let's discuss/track further in the dbuild repo: lightbend-labs/dbuild#188 |
without this change we get <name>core</name> in the pom which then confuses dbuild. with this change we get <name>cats-core</name>. and the same for cats-macros. this is needed for compatibility with the Scala 2.12 community build; details at typelevel#1396
Use friendly name in POM for published artifacts - fixes #1396
Similar fix (typelevel/cats#1426) and issue (typelevel/cats#1396) to Cats.
if I do
sbt coreJVM/publishLocal
and inspect the resultingcats-core_2.11.pom
I see:instead of the expected
cats-core
.this then confused dbuild in the context of the Scala 2.12 community build, since the macro-compat project (attn @milessabin) also has a
org.typelevel#core
and the duplication caused dbuild to complain.I am not a pom/maven/ivy jockey at all and I have basically zero idea what the implications of the
<name></name>
part of a pom are. but it seems plausible to me that this could cause other sorts of tooling type problems in other contexts.I didn't check to see if other subprojects are affected.
after
set name in coreJVM := "cats-core"
or witha correct pom is generated. what the difference between
moduleName
andname
is I have no ideaThe text was updated successfully, but these errors were encountered: