This message was deleted.
# dependency-management
s
This message was deleted.
s
If I import just the generated toml file it works fine
Copy code
from(files("../test-catalog/build/version-catalog/libs.versions.toml"))
v
What does
./gradlew outgoingVariants
in the catalog build say?
Your case is not really similar to Giuseppe's as he did not publish a version catalog toml, but had a settings plugin that defines the catalog, but then tried to import it as published toml which of course failed.
s
sorry, I only meant it was similar in that it was the exact same error message.
Copy code
test-catalog on  1 [✘!] via 🅶 v8.0.1 via :coffee: v17.0.5 via 🅺 v1.9.10 on :cloud:  (us-west-2) 
❯ ./gradlew outgoingVariants

> Task :outgoingVariants
--------------------------------------------------
Variant versionCatalogElements
--------------------------------------------------
Artifacts for the version catalog

Capabilities
    - a:catalog:unspecified (default capability)
Attributes
    - org.gradle.category = platform
    - org.gradle.usage    = version-catalog
Artifacts
    - build/version-catalog/libs.versions.toml (artifactType = toml)


BUILD SUCCESSFUL in 903ms
1 actionable task: 1 executed
and for my ‘real’ project
Copy code
pricing-version-catalog on  1 [!] via 🅶 v8.0.1 via :coffee: v17.0.5 via 🅺 v1.9.10 on :cloud:  (us-west-2) took 12s 
❯ ./gradlew libs:outgoingVariants

> Configure project :buildSrc
WARNING: Unsupported Kotlin plugin version.
The `embedded-kotlin` and `kotlin-dsl` plugins rely on features of Kotlin `1.8.10` that might work differently than in the requested version `1.8.20`.

> Configure project :
Reckoned version: 0.0.1-rc.0.3+20231030T204230Z

> Task :libs:outgoingVariants
--------------------------------------------------
Variant versionCatalogElements
--------------------------------------------------
Artifacts for the version catalog

Capabilities
    - pricing:libs:0.0.1-rc.0.3+20231030T204230Z (default capability)
Attributes
    - org.gradle.category = platform
    - org.gradle.usage    = version-catalog
Artifacts
    - build/version-catalog/libs.versions.toml (artifactType = toml)


BUILD SUCCESSFUL in 817ms
10 actionable tasks: 1 executed, 9 up-to-date
it includes a version number, but specifying that version number makes gradle attempt to resolve from a repository rather than the included build.
v
Hm, yeah, you are hitting this: https://github.com/gradle/gradle/issues/18847 😞
s
I actually saw that Issue, but it states that it’s a consequence of them being part of the same build. Mine aren’t, they’re two completely separate git repos. There’s no connection between the two.
v
That's just you misinterpreting :-)
s
(that’s also why I mentioned removing the hyphens from my artifact name, as it’s mentioned in that pr)
v
Click on "edited" on the first post and look at the original first description
v
Then melix said this cannot work do it other way
then OP tried other way and said also does not work
Then he was asked to rewrite the issue to be like this
s
hm.
v
so just ignore first couple of comments, it is exactly your issue
s
so it’s not possible to include version catalog at all then. at least currently. that’s annoying
v
Seems so, yes. Only if you have it like Giuseppe, having a settings plugin that defines the catalog
s
hm. I do have a settings plugin for other stuff, but I didn’t want to overload that to have the version catalog too…