Skip to content

GitLab

  • Menu
    • Projects Groups Snippets
      Help
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • G gitlabhq1
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 21
    • Issues 21
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 12
    • Merge requests 12
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Infrastructure Registry
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • gpt
  • large_projects
  • gitlabhq1
  • Merge requests
  • !3240

Merged
Created 12 years ago by Administrator@rootOwner

Fix Wiki migration task and add more test coverage.

  • Overview 3
  • Commits 1
  • Changes 3

Created by: DanKnox

Check the commit message for details on what has been added. I threw in a ton more test coverage for every weird case I could think of. I did find an error in the code that has now been fixed. I'm hoping that error was the root cause of the problem.

Unfortunately, I was unable to reproduce the exact stack trace that was shown in issue #3234 (closed). I did figure out that the error was not related to my original guess. The migration task was already set up to ignore changes in the page title and keep the page title matching the page slug.

I also added more verbosity to the logging so if someone does experience another problem after this bug fix is in place it will be much easier to tell which Wiki page is causing the issue.

Rollback From First Migration

I also added a migration rollback task that removes the repositories created by the first pass of the wiki migration task. This command should be executed before attempting the migration again.

If you have already attempted a migration previously...

bundle exec rake gitlab:wiki:rollback RAILS_ENV=production
# then run
bundle exec rake gitlab:wiki:migrate RAILS_ENV=production

This should complete a successful migration without any duplication.

  • You're only seeing other activity in the feed. To add a comment, switch to one of the following options.
Please register or sign in to reply
  1. 17 Mar, 2013 1 commit
    • Dan Knox's avatar
      Fix Wiki migration task and add more test coverage. · 330fe416
      Dan Knox authored 12 years ago
      There was an error in the #extract_attributes_from_page method that
      caused an exception when checking to see if a page named "Home"
      already exists.
      
      The check occurs to handle the renaming of the main index page to
      "Home" to match the Gollum standard. If there is already a page
      called "Home" then the migrator will leave that page and create
      the Index page as usual. Users will need to manually rename their
      old "Home" page to something else then rename their "Index" page
      to "Home". Fortunately, I would be highly surprised if this case
      ever comes up.
      
      I also added more verbosity to the logging so if an error does
      occur, it will be easier to track down which Wiki page is causing
      the problem.
      330fe416
0 Assignees
None
Assign to
0 Reviewers
None
Request review from
Milestone
No milestone
None
None
Time tracking
0
Labels
None
Assign labels
  • No matching results
  • Manage project labels
Lock merge request
Unlocked
participants
Reference:
Source branch: github/fork/DanKnox/fix_wiki_migrator

    0 pending comments

Menu

Projects Groups Snippets
Help