Multiple bugs with gitlab bridge.
Hi,
Playing with git-bug on a existing gitlab repository with a few existing issues on the vendor's bug tracker, I ran trough the following errors:
After having successfully configured the bridge I could import the gitlab issues as well as creating a couple of local issues with git bug add, so far so good. Then, I meet the following errors:
- when doing again
git bug bridge pull, issues are duplicated with new hashes. - nothing is exported when doing
git bug bridge push, it jus returnsexported 0 issues with myBridge bridge.
I've tested the bridge on a freshly created repo on gitlab, again the first steps goes well, but this time when doing git bug bridge pull a second time to test if duplicates arise, I got this crash:
panic: runtime error: index out of range [-1]
goroutine 51 [running]:
github.com/MichaelMure/git-bug/bridge/gitlab/iterator.(*issueIterator).Value(...)
/home/dtrckd/src/_sink/git-bug/bridge/gitlab/iterator/issue.go:38
github.com/MichaelMure/git-bug/bridge/gitlab/iterator.(*Iterator).NextIssue(0xc0010ba000, 0xc000043dd0)
/home/dtrckd/src/_sink/git-bug/bridge/gitlab/iterator/iterator.go:86 +0x244
github.com/MichaelMure/git-bug/bridge/gitlab.(*gitlabImporter).ImportAll.func1(0xc000260100, 0xc0000aed00, 0xc0010bc000)
/home/dtrckd/src/_sink/git-bug/bridge/gitlab/import.go:70 +0x547
created by github.com/MichaelMure/git-bug/bridge/gitlab.(*gitlabImporter).ImportAll
/home/dtrckd/src/_sink/git-bug/bridge/gitlab/import.go:66 +0x146
Similar scenario on Github seems to work fine.
Version:
git-bug version: 0.7.1-dev-28c3ee3b71
github.com/xanzy/go-gitlab v0.29.0
go version go1.14.1 linux/amd64
Gitlab: 12.9.2 (self hosted)
OS: Linux 4.19.0-8-amd64 / Debian 10 x86_64