Opened 8 years ago
every 51'st changeset is not imported from the repository
|Reported by:||Dimitri Tarassenko||Owned by:||Lewis Baker|
I am using a large and old repository with ~9000 (nine thousand) changesets. I have noticed a few errors here and there when I started using RepoSearch plugin, in particular, that a lot of changesets are missing. While tracking this down I found the pattern that all missing changesets would differ in number by 51.
While in Perforce numbered changesets can be canceled, leaving a gap in their sequence, you can find if you are missing changesets by executing this:
select cast(rev as integer)-1 from revision where cast(rev as integer)-1 not in (select rev from revision) order by cast(rev as integer);
NOTE: this is Postgres version, I am sure SQLIte will be similar.
I was able to get this fixed by changing "batchsize = 50" to "batchsize = 1000000" in api.py and repos.py, but this obviously is a workaround rather than a solution.
I am positive the bug is there because when I tried it with batchsize = 1000 I was missing changesets 1001, 2002, 3003 and so on.