Closed gedw99 closed 3 years ago
I also did the exact same steps to repro, but instead upgraded github.com/gorilla/mux and it works fine, even when i run it again and again.
SO must be something to do with the github.com/blugelabs/bluge package...
Curious to know whats going on, and if it relates to https://github.com/oligot/go-mod-upgrade/issues/2
Hi,
This is a transitive dependency problem.
When updating github.com/blugelabs/bluge to version 0.1.7, we also update github.com/RoaringBitmap/roaring to version 0.9.1 (see commit https://github.com/blugelabs/bluge/commit/ac312c52ba3f0bd6475cfc2e3929a874c221880d#diff-33ef32bf6c23acb95f5902d7097b7a1d5128ca061167ec0716715b0b9eeaa5f6), which adds the (faulty) dependency to github.com/RoaringBitmap/real-roaring-datasets@v0.0.0-20190726190000-eb7c87156f76.
This has actually been removed recently (see commit https://github.com/RoaringBitmap/roaring/commit/e68bbda56edf220b9d320eb1fac4089502e608f0#diff-33ef32bf6c23acb95f5902d7097b7a1d5128ca061167ec0716715b0b9eeaa5f6). So, to solve the problem, we should first update github.com/RoaringBitmap/roaring to version 0.9.4 in github.com/blugelabs/bluge (via a pull request for example). Then, wait for github.com/RoaringBitmap/roaring to release a new version with this change (something like v0.1.8), and finally update to this version.
Hoping this helps.
thanks @oligot for digging into it.
that makes sense and what i figured was going on.
With go 1.17 they are changing the go .mod i read today in the release notes. https://golang.org/doc/go1.17#go-command "Prunes Module Graphs"
I have not tried it yet. It's going to change how transitive dependencies are modelled. Will be interesting to see how go-mod-upgrade is effected.
The idea of course is for the use case i hit to be sorted out so that the CLI tells you , hints what you need to do maybe. No tool is perfect so hinting to the user what to do might be a way to solve it ?
I didn't know about this new change in Go 1.17, thanks for the link!
I'll try to update to Go 1.17 soon, and see how this affect go-mod-upgrade.
I just tested with Go 1.17 and the problem disappear entirely :+1: Could you try it on your side and see if it also works for you ?
hey @oligot Yep i just tried it and it works :)
very nice to use... thanks for remembering to tell me...
also beer-search go.mod is on go 1.14, and still works, so will work on old repos too. YEAH :)
Will close this issue.. thanks again for this tool.
thanks for this great tool.
I ran it and it worked on this repo.
But then when i ran it again it failed, and i am eager to understand where the problem is so we can make this tool better.
steps to reproduce
Get the git repo and run it:
Now do a go mod upgrade, selecting the github.com/blugelabs/bluge for upgrade.
Now I run again and it works fine:
But now here is the bug, when i try to rerun the go mod upgrade again: