gh-gei icon indicating copy to clipboard operation
gh-gei copied to clipboard

Issue with Migrating Repository with Skip Release Flag

Open Richard-Barrett opened this issue 11 months ago • 1 comments

Description

Repositories with large metadata linked to pull requests, pull request branches, and a lot of releases and tags are not properly skipped when adding in the --skip-releases flag for migrating a repository.

Example Command:

gh gei migrate-repo --github-source-org OrganizationA --source-repo target-repo--github-target-org OrganizationB --target-repo. --skip-releases

Requriements

  1. Install gh
  2. install the plugin
  3. have two github organizations

Reproduction Steps

  1. Create a Repository in Organization A
  2. Create like 3000+ branches
  3. Create 3000+ releases and tags
  4. Create 300+ Pull Requests with Lorem Ipsum Dummy Data and an Attachment
  5. Create an Organization B
  6. Migrate Repository from Organization A to Organization B
  7. Watch it Fail

When you run it you will get an error related to the following:

[2024-12-17T15:29:15Z] INFO -- Migration started by MigratorsName from <source_repo> to <target_repo>
[2024-12-17T15:29:15Z] INFO -- Migration ID: <some_id>
[2024-12-17T15:29:15Z] INFO -- -----------------------------
[2024-12-17T15:29:16Z] INFO -- Git source migration started
[2024-12-17T15:49:28Z] INFO -- Git source migration completed
[2024-12-17T15:49:28Z] INFO -- -----------------------------
[2024-12-17T15:49:28Z] INFO -- Extraction started
[2024-12-17T20:29:21Z] ERROR -- ExtractRepoArchive: Repository metadata took too long to generate
[2024-12-17T20:29:47Z] ERROR -- ExtractRepoArchive: Repository metadata took too long to generate
[2024-12-17T20:29:51Z] ERROR -- ExtractAndLoadAttachmentsResumableJob: Metadata archive attachments could not be extracted for migration with url https://github.com/OrganizationA/target-repo and metadata id <metadata_id>.
[2024-12-17T20:29:51Z] ERROR -- ArchiveTimeoutError
[2024-12-17T20:29:51Z] INFO -- Extraction failed
[2024-12-17T20:29:52Z] INFO -- -----------------------------
[2024-12-17T20:29:52Z] INFO -- Migration failed
[2024-12-17T20:29:52Z] INFO -- -----------------------------

Richard-Barrett avatar Dec 19 '24 23:12 Richard-Barrett

I tried to use the --skip-releases flag as well as I couldn't migrate a repo because it had too much metadata. Using this flag made no difference to the size of the metadata, so it doesn't seem to be working.

AXDOOMER avatar Jan 24 '25 20:01 AXDOOMER