Skip to content

[Refactor:Autograding] Remove python-dateutil dependency#12426

Merged
bmcutler merged 12 commits intoSubmitty:mainfrom
HasTheDev:remove-dateutil-dependency
Mar 11, 2026
Merged

[Refactor:Autograding] Remove python-dateutil dependency#12426
bmcutler merged 12 commits intoSubmitty:mainfrom
HasTheDev:remove-dateutil-dependency

Conversation

@HasTheDev
Copy link
Contributor

Why is this Change Important & Necessary?

This PR removes the python-dateutil dependency. We already have a strong internal submitty_utils/dateutils parser, so using an external library for the same task is not necessary. Moving to a single parser simplifies the codebase and makes us less dependent on external tools.

Closes #11344

What is the New Behavior?

The functionality doesn't change for normal users. The backend has been changed to use the internal Submitty utilities for all date string parsing instead of the external dateutil library.

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

  1. Check that python-dateutil isn't listed in .setup/pip/system_requirements.txt.
  2. Verify that there aren't any import dateutil statements left in the Python source code (I've checked this with grep).
  3. Run any action involving date parsing to make sure no ModuleNotFoundError appears.

Automated Testing & Documentation

  1. Unit Tests: I ran the internal utility tests locally: python3 -m unittest python_submitty_utils/tests/test_dateutils.py. All 15 tests passed.
  2. End-to-End: Verified basic submission cycles in a local Vagrant environment.
  3. Documentation: No changes to submitty.org are needed for this backend change.

Other information
Breaking Change? No.

Migrations? No.

Security? Yes, slightly improved by reducing the number of third-party packages.

Copy link

@Farhanxikram Farhanxikram left a comment

Choose a reason for hiding this comment

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

Functionality review:

  1. python-dateutil has been removed from the system requirements file
  2. I used grep to search for "From dateutils" and there were no instances of that, I also checked "import dateutils" and all dateutils were imported from submitty utillities and not sourced externally
  3. I pip removed python's date utils from my VM and the tests passed, and dates were completely fine on the webpage side (I was able to edit assignments as an instructor and change dates completely fine)

@github-project-automation github-project-automation bot moved this from Seeking Reviewer to Awaiting Maintainer Review in Submitty Development Feb 13, 2026
@HasTheDev
Copy link
Contributor Author

Thank you for the review and the detailed feedback, @Farhanxikram!
I’m glad the tests passed on your VM. I'm looking forward to the merge and will be looking for my next issue to contribute to soon.

@HasTheDev HasTheDev changed the title Remove python-dateutil dependency [Refactor:Autograding] Remove python-dateutil dependency Feb 15, 2026
@HasTheDev HasTheDev changed the base branch from main to patch_customization_migration February 15, 2026 12:09
@HasTheDev HasTheDev changed the base branch from patch_customization_migration to main February 15, 2026 12:09
@HasTheDev HasTheDev changed the base branch from main to patch_customization_migration February 15, 2026 12:33
@HasTheDev HasTheDev changed the base branch from patch_customization_migration to main February 15, 2026 12:33
@codecov
Copy link

codecov bot commented Feb 16, 2026

Codecov Report

❌ Patch coverage is 33.33333% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 21.65%. Comparing base (cdd2676) to head (f26d4a9).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff              @@
##               main   #12426      +/-   ##
============================================
- Coverage     21.65%   21.65%   -0.01%     
  Complexity     9638     9638              
============================================
  Files           268      268              
  Lines         36233    36230       -3     
  Branches        486      486              
============================================
- Hits           7847     7845       -2     
+ Misses        27904    27903       -1     
  Partials        482      482              
Flag Coverage Δ
autograder 21.32% <33.33%> (-0.07%) ⬇️
js 2.04% <ø> (ø)
migrator 100.00% <ø> (ø)
php 20.68% <ø> (ø)
python_submitty_utils 80.08% <ø> (ø)
submitty_daemon_jobs 90.72% <ø> (ø)

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.

Copy link
Contributor

@williamschen23 williamschen23 left a comment

Choose a reason for hiding this comment

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

Fix Lint

@github-project-automation github-project-automation bot moved this from Awaiting Maintainer Review to Work in Progress in Submitty Development Feb 17, 2026
Copy link
Contributor

@williamschen23 williamschen23 left a comment

Choose a reason for hiding this comment

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

Lint still fails, please fix!

@williamschen23 williamschen23 moved this from Work in Progress to Awaiting Maintainer Review in Submitty Development Feb 28, 2026
@HasTheDev
Copy link
Contributor Author

Hi @Farhanxikram! Thanks so much for approving the code! It looks like the CI workflows are currently paused and 'awaiting approval' to run. Could someone please trigger them when they have a second? I'll keep an eye on the results.

@bmcutler bmcutler merged commit f13ac7c into Submitty:main Mar 11, 2026
@github-project-automation github-project-automation bot moved this from Awaiting Maintainer Review to Done in Submitty Development Mar 11, 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.

Potentially unnessecary python-dateutil usage

4 participants