Splitties / refreshVersions

Life is too short to google for dependencies and versions
https://splitties.github.io/refreshVersions/
MIT License
1.66k stars 107 forks source link

Throw exception / cancel build instead of adding failureComment #647

Open jschneider opened 1 year ago

jschneider commented 1 year ago

The current behavior if a repository is unreachable:

e.g.

failed to check repo https://plugins.gradle.org/m2/ Cause: network or server issue (class javax.net.ssl.SSLHandshakeException PKIX path validation failed: java.security.cert.CertPathValidatorException: validity check failed)

But the build finishes successfully.

I would prefer refreshVersions to throw an exception and fail the build.

Reasoning: I have automated refreshVersions in the CI pipeline. And those comments could end up being merged into "main".

LouisCAD commented 1 year ago

That was the initial behavior, but we changed it because it was a pain when one of the repos wasn't working.

We won't change it back, but we might consider adding an option for your use case. Any idea on the naming and configuration location?

jschneider commented 1 year ago

I started implementing this feature. But didn't find a good way to get the configuration into Write versions candidates using latest most stable version and get it

I didn't want to add a parameter - but probably it is necessary...