flow
flow copied to clipboard
Bug or feature request? Version.getFullVersion() returns flow-server version not main release version
Describe your motivation
Class Version is part of flow-server. Calling Version.getFullVersion() returns flow-server's version. This is confusing since a call like that is expected to return Vaadin Release Version. However artifacts within each Vaadin release can and will often not have synced version numbers. In this case I am using Vaadin Flow v24.3.9, but flow server is at v24.3.8.
Describe the solution you'd like
I would recommend to either bump flow server version to match main release version, or move class Version to where it better can represent the main release version so that developers can rely on the value returned from class Version.
Describe alternatives you've considered
I am displaying the Vaadin version property from pom.xml inside the client today, but this is wrong because the intended version in pom might be correct but the build may contain wrong artifact versions because of bad build, sync/reload issues, etc. The true Version should come from within the artifact itself.
Version is specific for Flow. To get the Vaadin version you can use Platform.getVaadinVersion()
Thanks for the information. Not trivial at all. In that case I will recommend renaming class Version to FlowVersion bacause it is confusing how it is now. At least document inside class Version that there is a Platform version option available which might be what you would want.
The Version class exists from ancient times. There's probably lots of existing code out there that relies on it so we would probably break stuff if we'd just change it. We would instead have to deprecated it and introduce a new class side-by-side. Not sure if that's worth the hassle. Maybe it would be enough to supplement the javadoc?
Yes just changing it would break stuff. So supplementing and deprecate would be a good solution. A minimum should be to update the javadoc so it is clear for the developers.