-
Notifications
You must be signed in to change notification settings - Fork 12.9k
Database: Update the xorm dependency to v0.8.1 #22376
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
Conversation
Thanks, I will have a look at it. |
@novalagung Would you be able to fix the failing tests? |
@aknuds1 sure |
@aknuds1 I just pushed some updates. all tests are passed now |
@novalagung Great, how did you fix the tests? I can't tell from the diff. |
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
@aknuds1 actually my changes did not touch the test codes at all. I only modified the go dotfiles and import paths. but somehow it causes the test to fail. Then I performed the |
@novalagung I found that the very last version of xorm (0.8.2) causes tests to fail. I am able to upgrade to 0.8.1 though, while your PR is on 0.8.0. I'm going to push my changes to your branch. |
@aknuds1 sure, thank you |
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.
LGTM!
I'd like to hear from my team mates before merging it, hopefully they can chime in. |
@novalagung I'm unable to reproduce your issue BTW:
It doesn't seem right to me either that an old version of github.com/go-xorm/core should change its module path? |
the error only occur when ➜ ~ mkdir app
➜ ~ cd app
➜ ~ go mod init app
➜ ~ go get -u github.com/grafana/grafana/pkg/tsdb
go: finding github.com/grafana/grafana/pkg latest
go: finding github.com/grafana/grafana/pkg/tsdb latest
...
go: github.com/grafana/grafana/pkg/tsdb imports
github.com/go-xorm/core: github.com/go-xorm/core@v0.6.3: parsing go.mod:
module declares its path as: xorm.io/core
but was required as: github.com/go-xorm/core |
@marefr What's your take on this, since you said there have been troubles upgrading xorm in the past. Would you want for this PR to upgrade only to the first xorm version (0.8.0) after their module path changed (to xorm.io/xorm)? |
@aknuds1 I'm a bit skeptic accepting this for the sake of supporting using tsdb package as dependency since there's not a problem currently for Grafana . We have had a lot of problems related to upgrading xorm historically with hidden breaking changes and upgrading needs detailed comparison/review of all their changes. If you still want to upgrade I agree that upgrading to the lowest version first is the way to go, but still detailed comparison/review of all their changes (all xorm packages that Grafana uses) is needed. |
@novalagung out of curiosity what are you using Grafana's tsdb package for? |
@marefr Thanks for the clarification! I guess we should make it a future task for ourselves to go through the paces of upgrading xorm, including reviewing and testing. At the time being, I figure it's not enough of a priority. |
@marefr actually I didn't use tdsb package exclusively on my work. I found out about the issue when I was stumble upon in stackoverflow, looking for recent unanswered questions. I found the issue and then decide to test it. |
This pull request has been automatically marked as stale because it has not had activity in the last 2 weeks. It will be closed in 30 days if no further activity occurs. Please feel free to give a status update now, ping for review, or re-open when it's ready. Thank you for your contributions! |
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
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.
LGTM
I merged with latest Grafana master and pushed to your repo. Will merge it once the checks finish :) |
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.
LGTM
@novalagung Thank you for contributing to Grafana! |
What this PR does / why we need it:
Upgrade xorm to 0.8.1.
The required dependency xorm is moved into gitea and the module name is changed. this causing go get on grafana generate an error