Skip to content

TICKET-637: Set course dates from term on LTI course creation#8057

Open
Naragod wants to merge 2 commits into
masterfrom
TICKET-637_auto_course_dates
Open

TICKET-637: Set course dates from term on LTI course creation#8057
Naragod wants to merge 2 commits into
masterfrom
TICKET-637_auto_course_dates

Conversation

@Naragod

@Naragod Naragod commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

Proposed Changes - ✨ New feature

Courses created through the Canvas LTI flow now start with term dates filled in. Before this change, instructors set both dates by hand after every course creation.

  • LtiConfig.get_course_dates turns the term into a four-month window. "Fall 2025" becomes Sep 1 to Dec 31, 2025.
  • The SIS ID term code (LSM999Y1-Y-LEC0101-20259) wins over the term name when both are present.
  • Canvas sends the term name through a new term_name custom claim.
  • When no term can be parsed, both dates stay unset and instructors set them as before.
  • Adapter files without get_course_dates keep working through a respond_to? guard.
Screenshots of your changes (if applicable) Screenshot 2026-07-13 at 10 48 00 PM Screenshot 2026-07-13 at 10 47 30 PM

Type of Change

(Write an X or a brief description next to the type or types that best describe your changes.)

Type Applies?
🚨 Breaking change (fix or feature that would cause existing functionality to change)
New feature (non-breaking change that adds functionality) X
🐛 Bug fix (non-breaking change that fixes an issue)
🎨 User interface change (change to user interface; provide screenshots)
♻️ Refactoring (internal change to codebase, without changing functionality)
🚦 Test update (change that only adds or modifies tests)
📦 Dependency update (change that updates a dependency)
📖 Documentation update (change that updates documentation)
🔧 Internal (change that only affects developers or continuous integration)

Checklist

(Complete each of the following items for your pull request. Indicate that you have completed an item by changing the [ ] into a [x] in the raw text, or by clicking on the checkbox in the rendered description on GitHub.)

Before opening your pull request:

  • I have performed a self-review of my changes.
    • Check that all changed files included in this pull request are intentional changes.
    • Check that all changes are relevant to the purpose of this pull request, as described above.
  • I have added tests for my changes, if applicable.
    • This is required for all bug fixes and new features.
  • I have updated the project documentation, if applicable.
    • This is required for new features.
  • If this is my first contribution, I have added myself to the list of contributors.

After opening your pull request:

  • I have updated the project Changelog (this is required for all changes).
  • I have verified that the pre-commit.ci checks have passed.
  • I have verified that the CI tests have passed.
  • I have reviewed the test coverage changes reported by Coveralls.
  • I have requested a review from a project maintainer.

Questions and Comments

(Include any questions or comments you have regarding your changes.)

@Naragod
Naragod requested a review from donny-wong July 14, 2026 02:48
@coveralls

coveralls commented Jul 14, 2026

Copy link
Copy Markdown
Collaborator

Coverage Report for CI Build 30036542150

Warning

No base build found for commit d10c644 on master.
Coverage changes can't be calculated without a base build.
If a base build is processing, this comment will update automatically when it completes.

Coverage: 90.533%

Details

  • Patch coverage: 123 of 123 lines across 4 files are fully covered (100%).

Uncovered Changes

No uncovered changes found.

Coverage Regressions

Requires a base build to compare against. How to fix this →


Coverage Stats

Coverage Status
Relevant Lines: 51592
Covered Lines: 47726
Line Coverage: 92.51%
Relevant Branches: 2470
Covered Branches: 1218
Branch Coverage: 49.31%
Branches in Coverage %: Yes
Coverage Strength: 127.95 hits per line

💛 - Coveralls

@donny-wong donny-wong linked an issue Jul 17, 2026 that may be closed by this pull request
@donny-wong

Copy link
Copy Markdown
Contributor

Looks good! Please update branch and I will approve. Thank you.

@donny-wong
donny-wong force-pushed the TICKET-637_auto_course_dates branch from 8d2ca66 to 551eecf Compare July 23, 2026 19:05
@donny-wong
donny-wong requested a review from david-yz-liu July 23, 2026 19:28
@donny-wong

Copy link
Copy Markdown
Contributor

@Naragod and @david-yz-liu, I noticed that when a course is created via LTI with the term "2026 Fall-Winter", MarkUs sets the course dates to Sept 1 – Dec 31. The same happens for full-year (Y) courses, e.g. LSM999Y1-Y-LEC0101-20269 in the SIS ID. Shouldn't these span Sept 1 – Apr 30? Or does a MarkUs course only cover a single term?

@david-yz-liu

Copy link
Copy Markdown
Collaborator

@donny-wong you're right, for year-long courses it should go Sept 1 - April 30

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Automate Course Start/End Dates via Canvas LTI

4 participants