-
Notifications
You must be signed in to change notification settings - Fork 189
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
fix version for legacy clients #3805
Conversation
💥 Acceptance test Core-API-Tests-ocis-storage-1 failed. Further test are cancelled... |
https://drone.owncloud.com/owncloud/ocis/11885/39/7
IMO the string correctly now has "10.11.0" but the fields major-minor-micro have other values - it looks like "major" is set to 0. |
Looking at the example json doc on the top of this page, I am not completely happy tbh. Why is If the productversion is not existing (oC10 Installations) or legacy clients use the That is my understanding. So my request for change here is only to always put a useful version into productversion. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See comment in Conversation
With the current code here, I get:
I too was thinking that we would immediately set |
@phil-davis @dragotin Seems that there is a big misunderstanding here. We create the real version only during the compiling of ocis.
2 and 3 have no real version because they are just checked out "somewhere in the wild" The commitID is sufficient for 2) because it really identifies the exact version. There is no point in adding a "invented" semver version. |
OK, I will let others discuss this. I am old-fashioned and used to oC10, which returns an "up to date" version value in core master when I query the |
Hmm, all development builds "base" on a previous stable version. And that could/should be used IMHO. Otherwise we will have to implement a special handling of 0.0.0 again in the clients, which will be error prone again. |
Ok, that would mean we need to maintain a version in the code which needs to be touched on every release, that makes me unhappy 😄 |
I think the clients should not do anything based on the |
yes, if I am locally testing a development branch, I build and run my local oCIS, then start a client to manually check that it talks OK, then it would be good if |
Hmm, that requires manually maintaining product versions in the code, not good IMO |
True - clients should only use it as an opaque string for reporting convenience. They can show the string somewhere to the user if they want to inform the user about the product+productversion of the server that client is connected to. Or put it in log files entries so that support people can know exactly what server the client was connected to at the time. Clients should never attempt to parse the string, and never attempt to "decide what to do" based on anything in the string. |
Yes, it would be awesome if clients would not have to put semantics on the version from status.php. Unfortunately, that has turned out to be not realistic in the past. All the conditions we had in the Desktop Client based on the version were there for a reason: Because we changed the API, some API data interpretation and such. I do not think that this can not happen again in the future. Thus, we just need a parseable version of the server. |
hm, how does go mod build versions for commit ids? it seems to pick the latest release, adds a minor and then the date and commit id: in go.mod how does it calculate the pseudo version number? https://stackoverflow.com/a/59440771 and https://www.golang.ir/ref/mod#versions we can use git like so:
|
"This branch is 3 commits ahead, 72 commits behind master." Has conflicts anyway, so needs a rebase. |
Kudos, SonarCloud Quality Gate passed! |
Why is the |
You mean, if we have it i two places, better have it in 3 places? |
I don't know what the difference between |
For consistency, yes. I can switch over to the information in |
Made owncloud/web#7045 to use information from |
ok so we can merge this and tackle a |
Description
Bugfix: Fix version number in status page
We needed to undo the version number changes on the status page to keep compatibility for legacy clients. We added a new field
productversion
for the actual version of the product.Related Issue
New Status values
https://localhost:9200/status.php and https://localhost:9200/status/
Capabilities
How Has This Been Tested?
Screenshots (if appropriate):
Types of changes
Checklist: