Skip to content
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

Change the default maxPerPage for gitbucket (#30392) #30425

Merged
merged 3 commits into from
Apr 12, 2024

Commits on Apr 12, 2024

  1. Change the default maxPerPage for gitbucket (go-gitea#30392)

    This patch improves the migration from gitbucket to gitea.
    
    The gitbucket uses it's own internal perPage value (= 25) for paging and
    ignore per_page arguments in the requested URL. This cause gitea to
    migrate only 25 issues and 25 PRs from gitbucket repository. This may
    not happens on old gitbucket. But recent gitbucket 4.40 or 4.38.4 has
    this problem.
    
    This patch change to use this internally hardcoded perPage of gitbucket
    as gitea's maxPerPage numer when migrating from gitbucket. There are
    several perPage values in gitbucket like 25 for Isseus/PRs and 10 for
    Releases. Some of those API doesn't support paging yet. It sounds
    difficult to implement, but using the minimum number among them worked
    out very well. So, I use 10 in this patch.
    
    Brief descriptions of problems and this patch are also available in
    go-gitea#30316.
    
    In addition, I'm not sure what kind of test cases are possible to write
    here. It's a test for migration, so it requires testing gitbucket server
    and gitea server, I guess. Please let me know if it is possible to write
    such test cases here. Thanks!
    jam7 authored and GiteaBot committed Apr 12, 2024
    Configuration menu
    Copy the full SHA
    d6a178f View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ecda80b View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    7509703 View commit details
    Browse the repository at this point in the history