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

kpm - not setting plugin version should possible in PluginNamingResolver #152

Open
xsalefter opened this issue Feb 8, 2024 · 0 comments

Comments

@xsalefter
Copy link
Contributor

If PluginNamingResolver created without specifying the pluginVersion, getPluginVersion() throw IllegalStateException. It is not correct, since we have a chances to analyzing version from stringContainsVersion.

IIRC, that assertion added when working with ArtifactAndVersionFinder, but as workaround, we can change that line in ArtifactAndVersionFinder with:

final String pluginNameAsArtifactId = pluginKey + "-plugin";

And then, we can remove PluginNamingResolver.of(pluginKey) static factory. And start to re-condider getPluginVersion() implementation. After all, none of operation in PluginNamingResolver should throw an exception, since even if we cannot found any version, it will return 0.0.0.

@xsalefter xsalefter changed the title kpm - not setting plugin version in possible kpm - not setting plugin version should possible in PluginNamingResolver Feb 8, 2024
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

1 participant