Skip to content

[Refactor:Developer] Refactor migrator setup from install#11896

Merged
bmcutler merged 9 commits into
mainfrom
submitty_install_database
Jun 19, 2026
Merged

[Refactor:Developer] Refactor migrator setup from install#11896
bmcutler merged 9 commits into
mainfrom
submitty_install_database

Conversation

@lavalleeale

@lavalleeale lavalleeale commented Jul 22, 2025

Copy link
Copy Markdown
Contributor

Why is this Change Important & Necessary?

Modularizing submitty_install is important because it will make it easier to manage which installation steps are run. The next steps will be to refactor the longer steps out of install_site.sh to allow them to be run separately when a developer is only working on one part of the site at a time.

What is the New Behavior?

The database migration and superuser checks are split into a new file. This will allow them to be run separately if desired as an example of the utility of refactoring the globals into get_globals.sh.

What steps should a reviewer take to reproduce or test the bug or new feature?

Automated Testing & Documentation

Other information

@codecov

codecov Bot commented Jul 22, 2025

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 21.45%. Comparing base (2bb39b3) to head (082a254).

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff            @@
##               main   #11896   +/-   ##
=========================================
  Coverage     21.45%   21.45%           
  Complexity     9896     9896           
=========================================
  Files           268      268           
  Lines         36967    36967           
  Branches        495      495           
=========================================
  Hits           7933     7933           
  Misses        28543    28543           
  Partials        491      491           
Flag Coverage Δ
autograder 21.32% <ø> (ø)
js 2.01% <ø> (ø)
migrator 100.00% <ø> (ø)
php 20.49% <ø> (ø)
python_submitty_utils 80.08% <ø> (ø)
submitty_daemon_jobs 91.13% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@bmcutler

Copy link
Copy Markdown
Member

poorly named. this is not setup or installation of the database. this is migration/maintenance/update of the database.

@lavalleeale lavalleeale changed the title [Refactor:Developer] Refactor database setup from install [Refactor:Developer] Refactor migrator setup from install Jul 28, 2025

@jeffrey-cordero jeffrey-cordero left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Refactoring the migration process into a separate script looks well-implemented, and this is helpful as we continue to reduce the size of the large install script.

@github-project-automation github-project-automation Bot moved this from Seeking Reviewer to Awaiting Maintainer Review in Submitty Development Jul 31, 2025
@bmcutler

Copy link
Copy Markdown
Member

@lavalleeale
Please fill out more of the template for the PR. "How to manually test" should not be skipped. And for automated testing, indicate that existing tests are sufficient, or describe what new automated tests are added in this PR, or indicate that an issue has been opened to expand the automated tests in a future PR.

@bmcutler bmcutler left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks ok except to make sure we don't attempt to run this on a worker.

Comment thread .setup/install_submitty/install_migrator.sh
@github-project-automation github-project-automation Bot moved this from Awaiting Maintainer Review to Work in Progress in Submitty Development Aug 8, 2025
@github-actions github-actions Bot added the Abandoned PR - Needs New Owner No activity on PR for more than 2 weeks -- seeking new owner to complete label Aug 23, 2025
@hyeenaa

hyeenaa commented Feb 10, 2026

Copy link
Copy Markdown
Contributor

I'm having trouble figuring out how to test the functionality. The code looks good and functional as far as I can see, but testing it on a worker machine is hard, given that workers generate and workers up do not seem to work whatsoever on this development branch.

@hyeenaa
hyeenaa self-requested a review February 10, 2026 20:35
@automateprojectmangement automateprojectmangement Bot moved this from Work in Progress to In Review in Submitty Development Feb 10, 2026

@dagemcn dagemcn left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was able to verify that workers would not run this script if the install script is run and I was also able to verify that the script works on a vagrant up with a migration and without. I also tested the functionality of the migrator script and it is still working as well.

@github-actions github-actions Bot removed the Abandoned PR - Needs New Owner No activity on PR for more than 2 weeks -- seeking new owner to complete label Jun 11, 2026
@bmcutler
bmcutler merged commit 4d87e7d into main Jun 19, 2026
17 of 26 checks passed
@bmcutler
bmcutler deleted the submitty_install_database branch June 19, 2026 16:36
@github-project-automation github-project-automation Bot moved this from In Review to Done in Submitty Development Jun 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

5 participants