refs OUT-5650
flag=none
Test plan:
Import CSV
See event fired in logs
See Outcome created
See OutcomeEdge created
Change-Id: Icecc690c97107dc4a03b4fa851ccd16e5acd18c3
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327456
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Wilmer Corrales <wilmer.corrales@instructure.com>
Reviewed-by: Dave Wenzlick <david.wenzlick@instructure.com>
QA-Review: Chrystal Langston <chrystal.langston@instructure.com>
Product-Review: Kyle Rosenbaum <krosenbaum@instructure.com>
why:
* previous implementation was never fully baked
* modal wasn't closing in response to the deep link from the tool
* values were not being set on the assignment
* close modal properly
* set all the same values on the assignment as
assignment_selection deep link response
closes INTEROP-8241
flag=none
test plan:
* install a 1.3 test tool with the assignment_selection and
submission_type_selection placements
* create a new assignment
* choose the External Tool submission type, and choose the 1.3 tool from the list
* pass back assorted data like
* title: 'a string'
* custom: {"hello":"there"}
* lineItem: {"scoreMaximum":2}
* iframe: {"width":678,"height":456}
* pass the content item back to canvas
* the points possible and title on the assignment should have changed
* save the assignment
* it should launch with the right size and custom params
* create a new assignment
* choose the tool directly from the submission type dropdown
* launch the tool, pass back similar data in the content item
* the same values should be set on the assignment
* save the assignment
* the same values should be set in the launch
Change-Id: I47b0d21c2a10f417235201b2722b2b9576c9c4af
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/329216
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Tucker Mcknight <tmcknight@instructure.com>
QA-Review: Tucker Mcknight <tmcknight@instructure.com>
Product-Review: Alexis Nast <alexis.nast@instructure.com>
fix issue where when a video media comment is submitted by a student
with assignments enhancements flag turned on, viewing the comment in
speedgrader will show the comment as audio instead of video
fixes EVAL-3479
flag=assignments_2_student
test plan:
- first stay on the master branch
- have the Assignment Enhancements - Student flag enabled
- have a course with an assignment, a student, and a teacher
- as the student, add a video media comment to the assignment
- as the teacher, go to speedgrader and click on the video media
comment
- see that the video is not shown and only the audio is displayed
- download the commit branch
- run a 'yarn' to update the canvas-media package to reflect changes
- as the student, add another video media comment to the assignment
- as the teacher, go to speedgrader and view both the existing video
comment and the new comment
- see that both video comments are fully displayed
Change-Id: I7299885419114b02a6f4f6a4ac91ed87220c1975
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328034
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Mysti Lilla <mysti@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
Reviewed-by: Spencer Olson <solson@instructure.com>
QA-Review: Kai Bjorkman <kbjorkman@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
closes LF-680
flag=differentiated_modules
test plan:
- have the flag on
- have an assignment and corresponding assignment override
- the override should be adhoc with a student in the set
- give the assignment and the override different due dates
- it is easiest to do these things in the UI
- in a rails console, set the unassign_item column to true
override.update_attribute(:unassign_item, true)
- AssignmentOverrideApplicator.assignment_overridden_for(assignment, user)
- expect the due_at column to be the due date of the assignment, not
the override.
- also test the changes to select_override_by_attribute
- run AssignmentOverrideApplicator.overridden_due_at(assignment, [override])
- expect the result to be the assignment's due date
Change-Id: I9216643aa7f372a241668e15b1f3bb762e9adf3d
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/329281
Reviewed-by: Jackson Howe <jackson.howe@instructure.com>
QA-Review: Jackson Howe <jackson.howe@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Product-Review: Sarah Gerard <sarah.gerard@instructure.com>
flag=none
selenium-webdriver dropped support for the "capabilities" keyword for
local drivers in version 4.12.0:
https://github.com/SeleniumHQ/selenium/blob/trunk/rb/CHANGES
Test Plan:
- specs pass
Change-Id: I1d26d093be199cb1b0661fd2cfddc2d4d1416c5f
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/329303
QA-Review: Spencer Olson <solson@instructure.com>
Product-Review: Spencer Olson <solson@instructure.com>
Reviewed-by: James Butters <jbutters@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
I also did a refactor in preparation for
the update mutation that will come later on.
closes VICE-3757
flag=discussion_create
test plan:
- Specs pass.
- Use the CreateDiscussionTopic mutation
with the is_announcement param set to
true. It should create an announcement
instead.
- Use the CreateDiscussionTopic mutation
with the locked param set to true.
It should create a locked announcement.
qa risk: low
Change-Id: I85e2620141529beca99633da45995372666a2c5c
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/329258
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Product-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
Reviewed-by: Jason Gillett <jason.gillett@instructure.com>
closes VICE-3758
flag=discussion_create
Test Plan
1. Open a create and an edit announcement without the flag
2. Open the create and edit with the new create flag on
3. Verify that the correct settings appear on both
4. Create a new Announcement
5. Verify that the correct parameters are sent to graphql
Note that saving the options will not create an announcement
Correctly yet. that is handled in the backend ticket
If "allow participants to comment is checked, then locked == false"
Change-Id: If9fe3ec3ce0dd91a6e4a6b579c770c5ec5ffdee8
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/329143
Reviewed-by: Chawn Neal <chawn.neal@instructure.com>
QA-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
Product-Review: Chawn Neal <chawn.neal@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
fixes LF-772
flag=none
Test plan
- In a course with an assignment, have a
student submit with a file or text
submission
- Have the teacher use "download all
submissions"
- Get the ID for the file (probably
from the Rails console)
- As a (possibly different) student
go to api/v1/files/:file_id for that
file
- Verify that the student can't see that
file
- As one of the student, create a
submission comment with an attachment
- Get the ID for the file
- As the other student try to access
the api/v1/files/:file_id and
verify that you can't
Change-Id: I38bc70dfdf10e17d7a64aba5234ee609010f8531
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328740
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Jacob DeWar <jacob.dewar@instructure.com>
Reviewed-by: Jacob DeWar <jacob.dewar@instructure.com>
Reviewed-by: Eric Saupe <eric.saupe@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
Product-Review: Mysti Lilla <mysti@instructure.com>
Some notes (will remove from message after code review):
- I had at first wanted to put this along with the code that finds the
latest due at date, which is in AssignmentOverrideApplicator, but this
involved several levels of changes, adding an attribute to the
Assignment model, and finally for the presence of an assignment vs
quiz. That seemed like too much.
- Putting the code in the VariableExpander involves both repeating a bit
of custom logic to determine teacher vs. student, and potentially
risking some incompatibility with the old dueAt expansion in some edge
cases (when sections have no students/enrollments), but seems like the
best way to go.
- This cannot go in SubstitutionsHelper because that doesn't have any
assignment in it
- The behavior of substituing an empty string vs. not subtituting at all
(the value is the literal "$Canvas.assignment.earliestDueAt.iso8601")
is different from `Canvas.assignment.dueAt.iso8601` (but the same as
`Canvas.assignment.dueAt`). This is to simplify things and to
standardize on ASSIGNMENT_GUARD. It appears that the behavior of
dueAt.iso8601 was just to avoid crashes.
flag=none
closes INTEROP-8228
Test plan:
- have an LTI tool
- create a course with three sections:
Section A
Section B
Section C
- enroll a student in Section A and Section B, but no student in Section
C. Note: for a section due date to take effect for a student, the
students enrollments need to be in an 'active' state (not
creation_pending). You can run
enrollment.update workflow_state: :active
- create an assignment of type external tool. Give it different
assignment dates for different students (in Assignment settings under
"Assign" you can specify different dates for different students or
sections)
- add the $Canvas.assignment.earliestDueAt.iso8601 expansion either
to the assignment's Lti::ResourceLink custom fields, or the tool
configuration custom fields.
- launch the tool as a student in each section. the date should be the
due date for that student, as defined by Section or Student overrides.
- as a teacher test the following scenarios (settings under "Assign")
(sample dates in October, November, December)
- Assign to Section A: November
Assign to Everyone Else: December
-> expected variable value: November
- Assign to Section A: November
Assign to Everyone Else: October
-> expected variable value: October
- Assign to Section A: November
Assign to Section B: December
Assign to Everyone Else: October
-> expected variable value: November
(all students are either in Section A or B)
- Assign to Section A: November
Assign to Everyone Else: no due date
-> expected variable value: November
- Assign to Section A: no due date
Assign to Everyone Else: November
-> expected variable value: November
- Assign to Section A: no due date
Assign to Everyone Else: no due date
-> expected variable value: ""
- Assign to Section A: no due date
Assign to Section B: no due date
Assign to Everyone Else: October
-> expected variable value: ""
- Assign to student 1: October
Assign to Everyone Else: November
-> expected variable value: October
Change-Id: Ie3a2896caf2eb002b3e32bd1688337a41523eb1d
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328020
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Tucker Mcknight <tmcknight@instructure.com>
QA-Review: Tucker Mcknight <tmcknight@instructure.com>
Product-Review: Alexis Nast <alexis.nast@instructure.com>
flag=none
closes EVAL-3455
Test Plan:
- go to assignment index page
- check that the search still works as expected
- ensure there is a magnify glass icon in the search box along with
placeholder text
Change-Id: Ida3e084480ed467dc6fc0a36aae16d41175a4b98
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328380
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Samuel Lee <samuel.lee@instructure.com>
Reviewed-by: Cameron Ray <cameron.ray@instructure.com>
QA-Review: Samuel Lee <samuel.lee@instructure.com>
Product-Review: Jody Sailor
Mark as “viewed” those files that can be previewed when accessing the
module item view
closes LF-796
flag = none
test plan
- In a course, create a module
- Upload different previewable files like docx, odf, pdf, pptx, xlsx
- Edit the module and add ‘view the item’ requirement to the files
- Act as a student and access the files through the module
- Expect the files get registered as ‘viewed’ on modules list
Change-Id: I85d1e464d7b8a951c466a088fc6d4c4a52d49124
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/329094
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Product-Review: Jonathan Guardado <jonathan.guardado@instructure.com>
Reviewed-by: Sarah Gerard <sarah.gerard@instructure.com>
QA-Review: Sarah Gerard <sarah.gerard@instructure.com>
add an update so that when a missing policy applicator gives a
student a grade for a missing assignment, it will also create a
content participation record for the student so that the badge
count matches the number of content participation records
fixes EVAL-3494
flag=none
test plan:
- have a course with a missing policy activated that sets a grade
for a missing assignment
- find a student you will test this with, and act as them and
view how many grade notifications they have and the badge count
number
- try to get this badge count to 0 before starting by viewing all the
grades or comments that have not been viewed
- if you can't get it to 0 due to an existing error with badge counts,
just remember what the badge count was before you move on
- create an assignment that is due in the next minute
- wait for that assignment's due date to pass
- in the rails console, run the missing policy applicator with this
command:
MissingPolicyApplicator.apply_missing_policies
- check the badge count for the student in the course and ensure
that it went up by one
- you should see a new grade notification (blue dot) for the student
in the course for the assignment that you just created and they
should have a grade of whatever the missing policy set it to
- ensure that viewing this grade by clicking it to go to the submission
and then going back to the grades page/refreshing the page updates
the badge count by decrementing it by one
Change-Id: I3fa1382480f9df0c6ed37b219eebc2289698b867
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328127
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Spencer Olson <solson@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
QA-Review: Samuel Lee <samuel.lee@instructure.com>
Product-Review: Cameron Ray <cameron.ray@instructure.com>
closes LF-676
flag=differentiated_modules
test plan:
- in a rails console
- find an assignment, and create a course assignment override
- ao = assignment.assignment_overrides.create!
- ao.update_attribute(:set_type, "Course")
- ao.update_attribute(:set_id, {course id of assignment})
- ao.save!
- run AssignmentOverrideApplicator.course_overrides(assignment,
{user in the course})
- expect to see the course override
Change-Id: I6199439bb9996c7e831fd09cce3705443e1ba727
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/329017
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
Reviewed-by: Jackson Howe <jackson.howe@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
QA-Review: Jackson Howe <jackson.howe@instructure.com>
Product-Review: Sarah Gerard <sarah.gerard@instructure.com>
Fixes FOO-3791
flag=none
Test Plan:
- Have course templates enabled
- Go to a sub account's settings page
- In the drop down for course templates, there should be no
option for "Unnamed Course"
Change-Id: I6ea3d4b0241d56ea3992678f5728e6ee4c8a10b2
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328837
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jason Perry <jason.perry@instructure.com>
QA-Review: Jason Perry <jason.perry@instructure.com>
refs VICE-3732
flag=student_grade_summary_upgrade
Test Plan:
- using includeUnsubmitted on submissionsConnection field
on assignment type
- should return all submissions including unsubmitted
Sample Query:
query MyQuery {
legacyNode(_id: "1019", type: Course) {
... on Course {
id
name
assignmentsConnection {
nodes {
_id
id
name
submissionsConnection(filter: {includeUnsubmitted: true}) {
nodes {
_id
id
state
}
}
}
}
}
}
}
Change-Id: I5e1280fef546768f665b5d91d246548358ef983b
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328845
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Omar Soto-Fortuño <omar.soto@instructure.com>
Product-Review: Drake Harper <drake.harper@instructure.com>
QA-Review: Chawn Neal <chawn.neal@instructure.com>
closes FOO-3334
closes FOO-3847
closes FOO-3848
flag=temporary_enrollments
test plan:
- enable temporary_enrollments feature flag on root account
- enable permissions: User - Temporary Enrollments
- create two users on account (user1/user2)
- create course add user1 as teacher
- add module/assignment and publish everything
- go to course/people page
- click the temporary enroll icon for user1
- add user2 as a temporary enrollment for user1
- save/close modal
- user1 and user2 should now have edit icons
- click edit icon for user2 to view the edit modal
- modal should show list of enrollments
- close modal and click edit icon for user1
- modal should show list of enrollments
- edit icon next to each enrollment
- trash icon next to each enrollment
- an add button at the top of the enrollments table
- existing and new tests pass
Change-Id: If5e962115bccfc6372a1c16d0b272b8444e3d6fc
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328490
QA-Review: Michael Hulse <michael.hulse@instructure.com>
Product-Review: Michael Hulse <michael.hulse@instructure.com>
Reviewed-by: Charley Kline <ckline@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
closes VICE-3774
flag=student_grade_summary_upgrade
Test Plan:
- add a custom grading scheme
- create an assignment
- set display points as "Letter Grade"
- add the custom grading scheme to the assignment
- go to the react student grades page
Change-Id: I4ce2c02d66363e5f30b430308e46fbbc59c37b4c
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328865
Reviewed-by: Derek Williams <derek.williams@instructure.com>
Reviewed-by: Chawn Neal <chawn.neal@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
Product-Review: Sam Garza <sam.garza@instructure.com>
closes LF-670
flag=differentiated_modules
test plan:
- test that all_assignment_overrides includes context_modules
- have a context module with an assignment, and an assignment override
- to create the assignment override, run
module.assignment_overrides.create!
- on the assignment within the module, run
assignment.all_assignment_overrides
- expect the module override to show up
- Add a user to the context module override
- one way to do so is to have a section with the user in it
then set the override's set_type to "CourseSection"
and set to the section (override.set_type="CourseSection" and
override.set = section)
- with the assignment from before and the user, run
AssignmentOverrideApplicator.overrides_for_assignment_and_user(
assignment, user)
- expect to see the context module override in the list
Change-Id: I4722a6fa78927149cff0a2b14e34367099e51a0a
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328577
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Product-Review: Sarah Gerard <sarah.gerard@instructure.com>
Reviewed-by: Jackson Howe <jackson.howe@instructure.com>
QA-Review: Jackson Howe <jackson.howe@instructure.com>
refs VICE-3774
flag=student_grade_summary_upgrade
Test Plan:
- add a custom grading scheme
- create an assignment
- set display points as "Letter Grade"
- add the custom grading scheme to the assignment
- should be able to query the grading standard
on the assignment type
Sample query:
query MyQuery {
legacyNode(_id: "1019", type: Course) {
... on Course {
id
name
_id
assignmentsConnection {
nodes {
_id
name
gradingStandard {
id
title
data {
baseValue
letterGrade
}
}
}
}
}
}
}
Change-Id: I65c08791a30f45900e982dc4f5eae21a532cb8fe
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328863
Reviewed-by: Omar Soto-Fortuño <omar.soto@instructure.com>
Product-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
add message to enhanced screen reader gradebook whenever a submission
has been resubmitted since the last time it was graded
closes EVAL-3360
flag=individual_gradebook_enhancements
test plan:
- skipped selenium test in srgb_grading_spec.rb for this ticket passes
- have a student with an assignment that has already been submitted
and graded
- as the teacher, go to the enhanced screen reader gradebook and select
the student and the assignment
- see that there is no message saying the assignment has been
resubmitted since it was last graded
- as the student with the assignment, resubmit the assignment
- as the teacher, go to enhanced screen reader gradebook and select the
student and assignment
- see that there is a message below the excuse checkbox saying that
the assignment has been resubmitted since it was last graded
- grade the assignment and see that the message disappears
Change-Id: I1012598c317334594e5f7d4acd20085d84bbcc4e
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/324523
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Jackson Huang <jackson.huang@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
closes AE-494
[skip-stages=Flakey]
[skip-crystalball]
several things going on here. in general, many of our monkeypatches
have been implemented in upstream, but in a vastly different way, so
we need to enable/configure those things
* `servers` is no longer accepted as a backwards compatible
configuration option; use `url`
* `database` is no longer accepted as a backwards compatible
configuration option; you _can_ use `db`, but preferable to
just use `url`
* no longer merge together redis.yml and cache_store.yml; if one
references the other, simply use the config from the other
* `nil_store` is no longer accepted as a backwards compatible
configuration option; use `null_store` (almost no one should
be explicitly using this anyway, so nbd)
* automatically not-even-trying when redis has previously failed
is now handled by redis-client's circuit breaker. be sure to
configure it in redis.yml/cache_store.yml/dynamic settings
* ignoring redis failures completely is already done by
RedisCacheStore; just rely on that, except for the few cases
where we use redis directly. some of these now take advantage
of a new `failsafe` kwarg (and often in combination with
pipelining), and some just handle it directly
* move logging to a RedisClient middleware
* move Twemproxy disallowed commands to a RedisClient middleware
* simplify Canvas.lookup_cache_store to have far less special casing
(in particular, patching is done automatically now)
* add ability to use Redis::Cluster (configure with `nodes` instead
of `url`)
* still override Redis::Distributed's HashRing, so that we don't
change our ring layout with the new MD5 hashing for servers. but
we got to vastly simplify the new class, due to upstream
refactorings allowing us to simply override a single method rather
than having to re-implement the entire class
* statsd reporting of redis errors is now simply passed as a callback
to RedisCacheStore, breaking CanvasCache's dependency on InstStatsd
Change-Id: I787672677a21994d40ae304dbac0fbf3a960a779
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/325641
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Build-Review: Cody Cutrer <cody@instructure.com>
why:
* to support the LTI Platform Storage spec, which requires a frame in
the same window as tool launches that can receive postMessages addressed
to the OIDC Auth domain (e.g. sso.canvaslms.com)
* since the RCE uses an iframe, tool launches from within an active RCE
editor can't use the existing forwarder frame in the main Canvas window
* the RCE uses the contents of the iframe as the source of truth for the
rich content it's editing, which means that just adding a forwarder
frame to the RCE's frame gets really messy really fast
solution:
* introduce a new LTI launch display type that only contains
the tool launch frame and the forwarder frame
* make sure all RCE content (existing and new) that uses LTI iframes
switches to that display type
* the new display type also forwards all normal postMessages to Canvas,
bypassing the RCE frame, so that the tool can address postMessages to
either `window.parent` with a `*` target origin, or
`window.parent.frames['post_message_forwarding']` with sso.canvaslms.com
as the target origin, just like normal tool launches
* if feature flag is disabled, new in_rce type behaves just like old
borderless type
* remove old RCE forwarder code, since all tool iframes will take care
of their own forwarding now
closes INTEROP-8205
flag=lti_rce_postmessage_support
test plan:
* before this commit is checked out:
* load a page with the RCE (new Page/wiki page is great)
* launch the 1.3 test tool from the RCE status bar and paste
`{"width":600,"height":400}` in the iframe box, and send back the
content item
* save the page
* check out this commit
* in a rails console, look at the rich content (WikiPage.last.body)
* the iframe url should look like `/retrieve?...&display=borderless`
* load the same page, and open the browser console
* Inspect the rich content either in the dev tools or switch to the
HTML editor - the iframe url should be `/retrieve?...&display=in_rce`
* repeat the tool launch to create another new iframe content item,
its url should also contain `in_rce`
* from the test tool launch inside the first content item, scroll down
to the postMessage section and send this message:
`{"subject":"toggleCourseNavigationMenu"}`, making sure the "use storage
target" box is checked (that will send the postMessage to the
sibling forwarder frame)
* the tool should receive a response message, posted in the console
* the left course nav sidebar should toggle open and closed
* uncheck the use storage target box (which will send the
postMessage to the wrapper iframe for forwarding) and send
the message again
* it should work again
* repeat this process with the second content item
* save the page and note that both iframe urls now include
"display=borderless" instead of "display=in_rce" when launching from
the saved page, but remain `in_rce` in the db
* confirm normal LTI launches not in the RCE also work, for sanity
Change-Id: I222a0533521f344a6c49a9204aab1c145157f85a
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326966
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Paul Gray <paul.gray@instructure.com>
QA-Review: Paul Gray <paul.gray@instructure.com>
Product-Review: Alexis Nast <alexis.nast@instructure.com>
we want to display the drop rules
in the assignment group modal when
there are no assignment
fixes EVAL-2851
flag= none
test plan:
- go to assignment and create a new group
- The drop rules should not appear
- After creating the group edit the group
- The drop rules should appear
- Move all assignments in the group and reload
- The drop rules should appear
Change-Id: I2cc14f853270cb2ea38e283ea87f75425d9b99a1
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327653
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Derek Williams <derek.williams@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
QA-Review: Samuel Lee <samuel.lee@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
fixes LF-755
flag=none
Test Plan:
- Create a course with an assignment having
submission type: annotatable_attachment
- Export said course to a new one
- Check the new one has the assignment and
attachment
- Export this second course to a third new one
- Check that this one also has the assignment
properly linked to the attachment
Change-Id: I674b1296c2e4ced68c4aa71bbaa0617de0749a29
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327992
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Mysti Lilla <mysti@instructure.com>
QA-Review: Mysti Lilla <mysti@instructure.com>
Product-Review: Luis Oliveira <luis.oliveira@instructure.com>
when using the Clear Badge Counts button & api endpoint, provide a
method in ContentParticipation that will query for "expected" submission
ids and any missing ContentParticipation items will be created.
fixes EVAL-3496
flag=none
test plan:
- have a student and a course with grades
- run the following command from rails console
ContentParticipation.where(user_id: <user_id>, content_item: 'grade')
.last.destroy
- act as student & load the grades page
- you should see the grade badge count is 1 but no blue dots
- reload the page. verify that the badge count is still there
- as an admin, view the students grade page and click on the "Clear
Badge Counts" button
- act as the student again and verify that the badge count is now 0
and not showing
Change-Id: Ib5549f3e08b6138a23270ef869cb4b532bd01d5e
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327833
Reviewed-by: Derek Williams <derek.williams@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Derek Williams <derek.williams@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
fixes FOO-3890
flag = none
Test plan:
Prerequisite: A course and user with a SIS ID
- Navigate to the user page for the user, and select to
Delete from ALL accounts.
- Run a SIS Import file to enroll the user into the existing course,
making sure the limit_section_privileges column is included
- Notice that the SIS Import doesn't show any enrollments added,
but there is a warning included
Change-Id: Icbeba5a5262b439676cfe629e7f1569498b8bfeb
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328752
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
QA-Review: August Thornton <august@instructure.com>
Product-Review: August Thornton <august@instructure.com>
closes VICE-3770
flag=react_discussions_post
test plan:
- Specs pass.
- Following the steps of the ticket,
have a discussion with a root entry
that contains 200 replies.
- Click on XXX Replies button.
- You should see a loading spinner
when the network request is happening
and also while rendering.
- While rendering there is a little slow
down but is much better experience than
the previous one that got stuck.
qa risk: low
Change-Id: I83f5e6f711c45ad01d8f3fd30f7b6e2f5417a3a8
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328686
Reviewed-by: Aaron Shafovaloff <ashafovaloff@instructure.com>
Reviewed-by: Drake Harper <drake.harper@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
Product-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
This commit squashes two previously seperate commits.
The individual test plans for each commit have been left intact.
Closes CNVS-59219,CNVS-59187
flag=site_admin_service_auth
Test Plan:
- Restart Canvas after pulling change
- Enable the flag
- Make valid requset to the token endponit using a
client_credentials grant. To be valid, the following
must be true:
- The client_id is a usable developer key global ID
- The client_secret is the api_key of the dev key
- The developer key has `internal_service: true`
- The developer key has an associated `service_user`
- Validate an acess token is returned
- Make an API request using the access token. Note
that you will need to set the User-Agent header to
something matching the Instructure service user
agent regexp. For example:
```
inst-service-ninety-nine/1234567890ABCDEF
```
- Tail web logs and validate the client identifier
use by request throttling middleware is:
```
service_user_key:<global developer key ID>"
```
Change-Id: I214823b708fedb3e811f123cb986a955f37b95c0
Allow blocking inst_access tokens by jti claims
Test Plan:
- Restart Canvas after pulling change
- Enable the flag
- Make valid requset to the token endponit using a
client_credentials grant. To be valid, the following
must be true:
- The client_id is a usable developer key global ID
- The client_secret is the api_key of the dev key
- The developer key has `internal_service: true`
- The developer key has an associated `service_user`
- Make an API request using the access token. Note
that you will need to set the User-Agent header to
something matching the Instructure service user
agent regexp. For example:
```
inst-service-ninety-nine/1234567890ABCDEF
```
- Tail web logs and validate the client identifier
use by request throttling middleware is:
```
service_user_key:<global developer key ID>"
```
- Decode the access token and note the `jti` claim value
- In a Canvas Rails console, add that jti value to
the request throttling blocklist:
```
Setting.set("request_throttle.blocklist", <jti value>)
```
- Attempt to use the token again and validate the http
response code is 403
- Attempt to make an API request with a standard access
token and validate throttling middlware does not raise
an error
- Attempt ot make a request with an active session and validate
throttling middleware does not raise an error
Change-Id: Ia8448094b7bf0281268bc3dd2d027bb934aa595c
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/323766
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Daniel Matyas Vincze <daniel.vincze@instructure.com>
Product-Review: Weston Dransfield <wdransfield@instructure.com>
Closes CNVS-59218
flag=site_admin_service_auth
Test Plan:
- Make a request to the tokens endpoint using a valid
client_credentials grant. The client_id and secret
should represent an active developer key with a
binding set to "on" and have an associated
`service_user` that is an account admin.
- Validate a token is returned and is usable to fetch
Canvas resources via API requests
- Set the developer key account binding's state to "off"
- Validate the token is no longer usable
- Re-enable the developer key account binding
- Soft delete the developer key and validate the access
token is still not usable
- Hard delete the developer key and validate the access
token is still not usable
Change-Id: Ife146151cbaf8ce32c12621b7ea036006d781124
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/323668
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Daniel Matyas Vincze <daniel.vincze@instructure.com>
Product-Review: Weston Dransfield <wdransfield@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
This commit squashes three previously seperate commits.
The end result is that Canvas issues "service user" access
tokens via a client_credentials grant. The tokens issued
are unencrypted inst_access tokens.
The individual test plans for each commit have been left intact
Closes CNVS-59194,CNVS-59194,CNVS-59215
flag=site_admin_service_auth
Test Plan:
- Create a developer key in your local site admin account
- Create a user in the site admin account and note
their ID. Also make then a site admin admin
- In a rails console, associate the user to the
key as a service user:
```
key = DeveloperKey.find(<new key>)
key.update!(service_user: User.find(<new user>))
```
- Enable the `site_admin_service_auth` flag
- Make a request the token endpoint using a client
credentials grant and valid client ID/Secret:
```
http POST 'http://canvas.docker/login/oauth2/token?\
client_id=<global dev key ID>&\
client_secret=<dev key api_key>&\
grant_type=client_credentials'
```
- Validate an access token is returned
- Use the token to make a request to `/api/v1/users/self`
and validate the token was genereted for the
service user
- Attempt to make the token request with an invalid
client secret
- Validate a token is not returned
- Attempt to make the token request with the associated
feature flag disabled
- Validate a token is not returned
- Make the service user's workflow_state "deleted" and
attempt to make the token request
- Validate a token is not returned
- Set the DeveloperKey's service_user_id to nil and
attempt the token request
- Validate a token is not returned
- Validate you are unable to retrieve a token when
the developer key is in a "deleted" state
Allow client_credentials service grant internally
Test Plan:
- Validate the test plan for g/323440 continues
to pass
- In addition, validate an access token cannot
be retireved via the client_credentials grant
type + service user unless the DeveloperKey
has `internal_service: true`
Use unecrypted inst_access tokens for client_credentials
Also refactor ClientCredentialsProvider initializer to
us kwargs for argument clarity
Test Plan:
- Make a valid token request using a client_credentials
grant type + a DeveloperKey associated with a
service_user
- Verify an access token is returned
- Verify the access token is associated with the
DeveloperKey's service user
- Verify the access token may be used as a bearer
token in Canvas API endpoints
Change-Id: Ib2a2a3beac1cc04712f8b594e31029471eb359dc
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326978
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Daniel Matyas Vincze <daniel.vincze@instructure.com>
Product-Review: Weston Dransfield <wdransfield@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
our AR initializer will otherwise attempt to instantiate an
ADHOC or a Noop if one of these methods is called on such an
override. this has tripped up notification code that calls
override.respond_to?(:course) && override.course
now that AssignmentOverride actually responds to :course
fixes CANVAS-M8H5
fixes CANVAS-M8HT
fixes CANVAS-M8AN
fixes CANVAS-M8BM
fixes CANVAS-M9K6
Change-Id: I1a7545842685ba1462fcd96e359bb2b79cdfeede
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328730
Reviewed-by: Spencer Olson <solson@instructure.com>
Reviewed-by: Jackson Howe <jackson.howe@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Jackson Howe <jackson.howe@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
why
* don't let one assignment validation error crash the entire job
* migrate all valid assignments and log the failed ones to Sentry
* assess number and type of failures (just weird data??) in Sentry
before fixing
closes INTEROP-8240
flag=none
test plan:
* install the lti 1.1 test tool but do it locally instead of using the
deployed version
* make sure to include the Assignment Selection placement
* create two assignments associated with the 1.1 tool
* in the rails console, find one of those assignments and change
its points_possible to nil
* install the 1.3 version of the 1.1 test tool (follow the instructions
at <test tool url>/1_3)
* installing it in the same context as the 1.1 tool should kick off
some prepare_direct_batch_for_ags jobs
* those should not fail
* the assignment that you didn't update should now have a
Lti::LineItem for it
Change-Id: I249ed50f835c9822994bf5677fdf285e1c4a6c1a
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328478
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Tucker Mcknight <tmcknight@instructure.com>
QA-Review: Tucker Mcknight <tmcknight@instructure.com>
Product-Review: Xander Moffatt <xmoffatt@instructure.com>
closes EVAL-3530
flag=custom_gradebook_statuses
Makes two changes:
1. Custom statuses can no longer be created, edited, or deleted from a
subaccount page (since custom statuses are only configurable at the root
account level).
2. The root account's custom statuses will be shown when viewing from a
subaccount page.
Test Plan:
1. Enable "Custom Status Labels for Submissions and Final Grades".
2. At the root account level, verify you can:
- View and edit Standard Statuses
- View, create, edit, and delete Custom Statuses
3. At the sub-account level (for a sub-account belonging to the root
account from step 1), verify you can:
- View the root account's Standard Statuses. You should not be able to
edit.
- View the root account's Custom Statuses. You should not be able to
add, edit, or delete.
Change-Id: I00a600caf58d2a309bc56ec9adb75a86700d4bf5
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328464
Reviewed-by: Derek Williams <derek.williams@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
Reviewed-by: Christopher Soto <christopher.soto@instructure.com>
QA-Review: Christopher Soto <christopher.soto@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
closes EVAL-3528
flag=apply_score_to_ungraded
Fixes an issue where "Apply Score to Ungraded" would throw an error when
the Assignment Group columns were being hidden in Gradebook.
Test Plan:
* Prerequisites:
- Enable the ‘Apply Score to Ungraded’ Account level feature flag
- Enable the ‘Enhanced Gradebook Filters’ Course level feature flag
1. Go to the Gradebook in a course, click the settings cog -> View Options.
Check the checkbox for "Hide Assignment Group Totals" and click
"Apply Settings".
2. In the total column header, click the 3-dots menu and click
"Apply Score to Ungraded". Enter a "0" in the input, check the checkbox
for "Apply missing status", and then click "Apply Score". Notice
that no error is thrown in the JS console and the score is applied as
expected.
3. Click the settings cog -> View Options. Uncheck the checkbox for
"Hide Assignment Group Totals" and click "Apply Settings".
4. In the total column header, click the 3-dots menu and click
"Apply Score to Ungraded". Enter a "0" in the input, check the checkbox
for "Apply missing status", and then click "Apply Score". Notice
that no error is thrown in the JS console and the score is applied as
expected.
Change-Id: I3b5c313498db603676dca46d8b7f99f4e0a5cda7
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328337
Reviewed-by: Rohan Chugh <rohan.chugh@instructure.com>
Reviewed-by: Christopher Soto <christopher.soto@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Kai Bjorkman <kbjorkman@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
this commit adds all availability dates should be shown
on the assignment details page like what is seen with
Classic Quizzes to maintain parity.
fixes EVAL-3113
flag=none
test plan:
- Create a new assignment with the available dates in
the future a due date, and an until date
- Create a new quiz with the available dates in
the future a due date, and an until date
- As a student navigate to the future assignment and
future quiz
- It should show assignment "This assignment is locked until..."
and should look like the quiz's show page
Change-Id: Id6037c6aeb38c2add1309d97346ff37386bca22a
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/325809
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Cameron Ray <cameron.ray@instructure.com>
Reviewed-by: Spencer Olson <solson@instructure.com>
Product-Review: Cameron Ray <cameron.ray@instructure.com>
QA-Review: Derek Williams <derek.williams@instructure.com>
flag = differentiated_modules
closes LF-652
Test plan:
- Find a course with a context_module
- PUT /api/v1/courses/:course_id/modules/:contex_module_id
/assignment_overrides with an "overrides" param JSON blob like
one shown in the API documentation for this commit
- In a rails console, run
`context_module.assignment_overides.active`
- Expect the module's overrides to be updated according to the
API request
- Expect a student using the API to get unauthorized
- Expect to get 404 when the flag is disabled
Change-Id: Ifc9f8d73714ba72a2deb133ac725dd07ee4a7aee
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327837
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Jackson Howe <jackson.howe@instructure.com>
fix issue where sending a submission comment with a file attachment
will lead to error sending submission comment
fixes EVAL-3475
flag=assignments_2_student
Test Plan:
- set the Assignment Enhancement - Student flag on
- have a course with a student and a teacher
- as the teacher, create an assignment with a Not Graded type in the
display grade as option menu
- as a student go into the assignment and press the Add Comment button.
- add a comment and attach a file, and submit the comment.
- see that the comment is successfully displayed.
Change-Id: I0a29b4235248f13e37d8b82c50565c71785753fb
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327883
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Cameron Ray <cameron.ray@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
Reviewed-by: Derek Williams <derek.williams@instructure.com>
Reviewed-by: Spencer Olson <solson@instructure.com>
QA-Review: Rohan Chugh <rohan.chugh@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
since they're on in production, they need to be turned on
for local development and jenkins to avoid sneaking bugs
into production
I intend to actually _remove_ the feature flags
and associated permission blocks in a subsequent commit
flag=none
closes FOO-3874
Change-Id: I98f7c043ae93cb1c0b4aef46999417af43684e55
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/308815
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: August Thornton <august@instructure.com>
QA-Review: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
fix outcomes cannot be added to a rubric for an external tool
assignment
closes EVAL-3443
flag=none
test plan:
- have a course and teacher
- as the teacher, create a new external tools assignment
- press the add rubric button and click on the Find Outcome link
- see that it opens a modal with the outcomes
Change-Id: I7156dc8ad69dbe70aa16f45cfaeec82d5076900e
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327132
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Derek Williams <derek.williams@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
QA-Review: Spencer Olson <solson@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
test plan:
- create a wiki page entry with content larger that 4k characters
- multiple embeddings should be created for single wiki page
- search query should work
- the UI should display the first page of search results
flag=smart_search
closes ADV-25
Change-Id: Ibc9b9ffffad4a6cfa8213012b54b2dd7b8f4752b
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328480
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
QA-Review: Jonathan Featherstone <jfeatherstone@instructure.com>
Product-Review: Jonathan Featherstone <jfeatherstone@instructure.com>
test plan:
- have redis enabled
- have a course in an account with a SIS ID
- do /api/v1/courses/X/enrollments and see that this ID
is shown in `sis_account_id`
- change the sis id of the account via a change_sis_id.csv
import
- repeat the API call and the new SIS ID should be seen
flag=none
fixes FOO-3728
Change-Id: Idf5177f7710247b10c2a7231494129f7281e843e
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328597
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: August Thornton <august@instructure.com>
QA-Review: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
this fixes the flacky spec that was not handling
the create draft comment modal from the speedgrader
comment section
closes EVAL-2664
flag=none
test plan:
- Make sure that docker-compose exec web bundle exec rspec
spec/selenium/grades/speedgrader/speedgrader_comments_spec.rb
passes without any errors
Change-Id: Iac2fcc3c966cd77160dc7c75b6849622f7121238
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326975
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
QA-Review: Kai Bjorkman <kbjorkman@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Closes QUIZ-12126
flag=none
Test Plan:
- Add the new variable expansion to a custom var in an installed
LTI tool
- Launch the tool and validate the variable is populated with the
global context ID
Change-Id: I4aa102e7f6e35968d8103be93ef7b843eb170f05
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327328
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Dustin Cowles <dustin.cowles@instructure.com>
QA-Review: Dustin Cowles <dustin.cowles@instructure.com>
Product-Review: Stephen Kacsmark <skacsmark@instructure.com>
flag=discussion_create
fixes VICE-3753
test plan:
- make sure studentplanner is enabled
in your account settings
- as a teacher create a discussion
- verify that you can add a TODO date
- save and publish
- verify that your todo date saves
Change-Id: I7e517a5c451f35727ade975c54890f62d7e0c98e
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328265
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Omar Soto-Fortuño <omar.soto@instructure.com>
Product-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
QA-Review: Chawn Neal <chawn.neal@instructure.com>
fixes INTEROP-8201
flag = none
test plan:
- using the 1.3 test tool, create an LTI 1.3 assignment
- make a note of the ID of the line item that is created
(might be easiest to do Lti::LineItem.last in a rails console)
- in the Canvas UI, edit the assignment's due date
- call the /api/lti/courses/:course_id/line_items/:line_item_id endpoint
- see that the end_date_time field matches the due date you gave the
assignment
Change-Id: If94edb3d795860c6746d2367e4799541a43aae8c
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326864
Reviewed-by: Xander Moffatt <xmoffatt@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Migration-Review: Alex Slaughter <aslaughter@instructure.com>
QA-Review: Xander Moffatt <xmoffatt@instructure.com>
Product-Review: Tucker Mcknight <tmcknight@instructure.com>
This adds a variable expansion which provides a list of subaccounts
(recursive) the launching user has admin rights too. This is needed by
Studio.
The code add in app/models/user.rb has been moved verbatim from MRA,
where it was previously written for another purposes. See corresponding
commit which removes it from there.
closes INTEROP-8207
flag=none
Test plan:
- have an account (not a root account) with at least one subaccount of
its own.
- make a user an admin in the account by going into account settings ->
admin.
- add a custom variable with the value "$Canvas.user.adminableAccounts"
to an LTI.
- launch the LTI as the user
- look at the LTI custom variable (HTTP request params for LTI 1.1, in
the JWT for LTI 1.3). You should see the account id you added the user
as an admin for, and the ids of all of its subaccounts.
Change-Id: I222efbc44b727bf6a02c8ab8e77851a2938fb5ed
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327509
Reviewed-by: Xander Moffatt <xmoffatt@instructure.com>
QA-Review: Xander Moffatt <xmoffatt@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Product-Review: Alexis Nast <alexis.nast@instructure.com>
It's the new default debugger in ruby 3.1. Rails switched to it in 7.0,
avoids issues with Zeitwerk, has a more modern interface based on
current IRB, supports Unix Domain Sockets for remote debugging,
promises even better future maintenance due to being part of Ruby,
etc.
Change-Id: Ieaa7872f1c0308b16ae180fdb16df5dd6caa87a8
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328241
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Isaac Moore <isaac.moore@instructure.com>
Build-Review: Isaac Moore <isaac.moore@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
flag=discussion_create
fixes VICE-3752
test plan:
- as a teacher or student, create a discussion,
click allow liking, save and publish
- verify that you can like discussion replies
- now create an allow liking discussion and also
check only graders can like, then save and publish
- verify only tas, teachers, and the like can like
- optional: (this takes a while to set up,
but is fully tested in selenium)
- - verify you do not see allow liking
checkbox in discussions created in homeroom courses
Change-Id: Ib309ab122d1602d550c00a3ff50f82efb8209150
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328037
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Chawn Neal <chawn.neal@instructure.com>
QA-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
Product-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
Multiple user merge data objects with the same from_user_id will
conflict with one another. In this case it was within minutes apart.
This is a problem as the split_db_users method will only split the
first occurrence, and then the second merge data object will fail
(at least when triggered through the UI/API and specified user merge data
object is not passed in as an arg)
Uniq by last in first out (LIFO)
fixes FOO-3844
refs FOO-3838
flag = none
test plan:
- create two active user merge data objects with the same from_user_id
and user_id combination
- run the split_db_users method and verify that the second merge data
object does not get picked up
- user merges should fail with a message about the user already being
merged with the same source / target user pair
(look to the specs for how to do this)
Change-Id: I5ed59308dfa8f376757995df0a161353606a91e8
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327694
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jason Perry <jason.perry@instructure.com>
QA-Review: August Thornton <august@instructure.com>
Product-Review: August Thornton <august@instructure.com>
closes LF-739
flag=none
test plan:
> Verify that the Course Pacing override title says
"Course Pacing" instead of "No Title".
Change-Id: Ic922df640229d6521538f9a4689a1bdceea977e0
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328057
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Juan Chavez <juan.chavez@instructure.com>
test plan:
- delete a page; its embeddings should be deleted
- update a deleted page body; it should not have embeddings created
- undelete the page; it should have embeddings recreated
flag=smart_search
closes ADV-36
Change-Id: Ib7ac7153e82e6a6508b73e748111ceba909f7cf1
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328054
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jonathan Featherstone <jfeatherstone@instructure.com>
QA-Review: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
instead of HTML content, which the model may not be equipped
to understand
flag=smart_search
closes ADV-26
Change-Id: I8b485d6badb1a06fee8682dafd4b11129b86db6a
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328053
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jonathan Featherstone <jfeatherstone@instructure.com>
QA-Review: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
The flag has been on for all accounts for a few weeks now.
fixes INTEROP-8138
test plan:
- tests pass
Change-Id: Ibe4e2b0257f8274bdf7f92bb78460ebb5e959d83
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327727
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Xander Moffatt <xmoffatt@instructure.com>
QA-Review: Tucker Mcknight <tmcknight@instructure.com>
Product-Review: Tucker Mcknight <tmcknight@instructure.com>
closes OUT-5859
flag=improved_lmgb
This ticket creates a modal that contains detailed
information for an outcome. This information includes
- Outcome Title
- Outcome Display Name
- Outcome Friendly Description (If FF is enabled)
- Outcome Description
The modal is accessed by selecting the dropdown
menu in the outcome column header and selecting the
"Outcome Description" option
Test Plan:
- Automatic: Test are sufficient and pass in Jenkins
- Manual:
- Enable Improved LMGB FF
- Enable Outcome Friendly Description FF (in Site Admin)
- Create an outcome with title, display name, friendly
name, and friendly description
- Create an outcome with a title, but no display name,
friendly name, or friendly description
- Navigate to Improved LMGB and open the description modal
- Check that all information is rendered correctly
according to the screenshots given in the JIRA ticket
- Check that the empty outcome displays the default modal
information with a working link to the Outcomes
Management page for the course
- Disable Outcome Friendly Description FF
- Check that "Friendly Description" is not rendered in the
outcome description modal
Change-Id: Ibf452c5da510211fe390e48e792c37f4c872b46b
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326939
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Product-Review: Kyle Rosenbaum <krosenbaum@instructure.com>
Reviewed-by: Martin Yosifov <martin.yosifov@instructure.com>
QA-Review: Martin Yosifov <martin.yosifov@instructure.com>
fix bug where a user cannot import a gradebook with a override score
and the custom gradebook statuses feature disabled.
closes EVAL-3513
flag=custom_gradebook_statuses
test plan:
- make sure custom_gradebook_statuses is OFF
- go to a course with final grade override scores enabled and displayed
in a gradebook.
- click on the Export button in the gradebook and export entire
gradebook
- in the csv you should see the override score column. make a slight
modification to the score and save the csv
- go back to the gradebook and click on the Import button
- Import the csv you just modified.
- Verify that you can now successfully import the csv
Change-Id: Ib4ff77df3b50dfb8aa7ad759daf65eb989968819
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328084
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Spencer Olson <solson@instructure.com>
Reviewed-by: Derek Williams <derek.williams@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
QA-Review: Spencer Olson <solson@instructure.com>
Product-Review: Cameron Ray <cameron.ray@instructure.com>
Closes QUIZ-12125
flag=none
Test Plan:
Exercise the accounts show endpoint with and without
the new "global_id" includes query param.
Validate the global_id is included in the response
body when the include query param includes it
Validate the global_id is not included in the
response body otherwise
Example requests:
With the global_id in the includes query param:
```
/api/v1/accounts/self?includes[]=global_id
```
Without the global_id in the includes query param:
```
/api/v1/accounts/self
```
Change-Id: I985409460dba228bedf95f63eb6e2e354e26fae4
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327327
QA-Review: Weston Dransfield <wdransfield@instructure.com>
Product-Review: Weston Dransfield <wdransfield@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jorge Arteaga <jorge.arteaga@instructure.com>
closes LF-647
flag=differentiated_modules
test plan:
- turn the flag on
- have a module with an assignment override:
in a rails console, find a module and run
context_module.assignment_overrides.create!
- go to that module's course's module page
- that module should have the 'View Assign To' link in
the module header
- click the 'View Assign To' link
- expect the new differentiated modules tray to open
- should open with the 'Assign To' tab selected
- tray should behave the same as it currently does when accessing it
via the the module menu
Change-Id: Ide2eb6427d40451a0c8cc77403c6b9f223b35777
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328090
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Sarah Gerard <sarah.gerard@instructure.com>
when a module has assignment overrides, show the "View
Assign To" link
closes LF-646
flag=differentiated_modules
test plan:
- turn on the flag
- in a rails console, find a module and create an assignment override
- context_module.assignment_overrides.create!
- go to that module's course's module page
- that module should have the 'View Assign To' link in
the module header
- turn off the flag
- ensure the 'View Assign To' link is no longer there
- turn the flag back on
- in a rails console, delete the assignment override for that module
- the 'View Assign To' link should no longer be on the module
Change-Id: Ie41a0fa10f385851849876523720cfc56f4bad59
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327895
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jackson Howe <jackson.howe@instructure.com>
QA-Review: Jackson Howe <jackson.howe@instructure.com>
Product-Review: Sarah Gerard <sarah.gerard@instructure.com>
It appears this is unused, and we only have active notifications anyway.
refs AE-238
flag=none
test plan:
- specs pass
Change-Id: I15e13bc2bee595ade68a68debdf6469d6fc2e559
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327919
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
Migration-Review: Cody Cutrer <cody@instructure.com>
QA-Review: Isaac Moore <isaac.moore@instructure.com>
Product-Review: Isaac Moore <isaac.moore@instructure.com>
fixes AE-516
as originally done in https://gerrit.instructure.com/c/canvas-lms/+/325872,
but setting auth_schema to request_body, and finding the OIDC id_token
in the token if it's only there, otherwise in the token params
Change-Id: I3ff97e151d2f03acdb96c0febcd2815cceab5497
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328039
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Build-Review: Cody Cutrer <cody@instructure.com>
flag=none
closes VICE-3693
Test Plan
1. Verify that the sis_import_id is exposed correctly
1a. Should match Enrollment.sis_batch_id from rails console.
Change-Id: Ia1af62aaf1788c825809f9a0234800ee846dd3e1
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327989
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
Reviewed-by: Drake Harper <drake.harper@instructure.com>
Product-Review: Drake Harper <drake.harper@instructure.com>
flag=react_discussions_post
flag=discussion_create
fixes VICE-3749
test plan:
- must have both feature flags turned on
- as a teacher, create a partially anonymous discussion
- verify you successfully create a partially anonymous discussion
and the topic post shows your real name
- as a student, when creating a partially anonymous discussion,
leave the "replying as" to the default setting (which is anonymous)
- save and publish
- verify you successfully create a partially anonymous discussion
and the topic post shows you as anonymous
- as a student, when creating a partially anonymous discussion,
change the "replying as" to your real name
- save and publish
- verify you successfully create a partially anonymous discussion
and the topic post shows your real name
Change-Id: Ie339e38ed32f2d89a353bd0b9907e318c53d098d
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328003
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jason Gillett <jason.gillett@instructure.com>
QA-Review: Drake Harper <drake.harper@instructure.com>
Product-Review: Caleb Guanzon <cguanzon@instructure.com>
closes LF-691
flag=none
test plan:
- Open the calendar view.
- Open the modal for create an event.
> Verify that the submit button is disabled until
user inputs a text.
- Clear the title field.
> Verify that you can't submit and red border/messages
appear in the field.
- Enter a text in title field.
> Verify that when clearing the date input, it is
auto-filled by the current date.
> Verify that when putting a invalid text in date input,
you can't submit and red border/messages appear in the field.
- Fill title and date fields with valid values.
- Click Submit.
> Verify that you can submit now.
Note: This should work when editing too. You can also
test title or date independently. When date is invalid
the frequency picker will use the current date.
Change-Id: I539aecfbc6e929b0a5814a5e2baa5ed0430f4fb2
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326871
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Juan Chavez <juan.chavez@instructure.com>
closes VICE-3745
flag=discussion_create
test plan:
- Specs pass.
- Go to the Discussion Create page.
- Set values for the fields available from
and until.
- Click on Save & Publish or save.
- It should persist correctly.
qa risk: low
Change-Id: I9f97007c410418a12315a7bf5126cd1b61bd05ce
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327999
Reviewed-by: Caleb Guanzon <cguanzon@instructure.com>
Product-Review: Caleb Guanzon <cguanzon@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Jason Gillett <jason.gillett@instructure.com>
why:
* pre-creating the attachments before inst-fs
upload keeps them in the "deleted" state
* other code paths including submitting or non-instfs eventually mark
the attachments as "available"
* this one was overlooked and did not, making the file download broken
closes INTEROP-8230
flag=ags_scores_multiple_files
test plan:
* enable the ags_scores_multiple_files flag
* set up inst-fs for your local canvas, following
the inst-fs README
* with an LTI 1.3 tool present in a course
* create an assignment associated with the tool
* follow the instructions in doc/lti_manual/11_testing.md to make an AGS
call to the Score API
* the test tool UI for the assignment now allows for AGS calls
* or you can use an HTTP client of your choice
* the body for the Score call should look like:
```
{
"userId":"2", // replace this
"timestamp":"2023-08-18T17:03:21Z",
"activityProgress": "Completed",
"gradingProgress": "FullyGraded",
"scoreGiven": 5,
"scoreMaximum": 5,
"https://canvas.instructure.com/lti/submission": {
"content_items": [
{
"type": "file",
"url": "https://example-files.online-
convert.com/document/txt/example.txt",
"title": "File the first",
"media_type": "application/pdf"
},
{
"type": "file",
"url": "https://example-files.online-
convert.com/document/txt/example.txt",
"title": "File the second",
"media_type": "application/pdf"
}
]
}
}
```
* Go to the assignment and to speedgrader
* click the Download button by each file
* the file should successfully download
Change-Id: I6d2c918fcf35eabe251e3664e1ab96838cd5900c
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326964
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Tucker Mcknight <tmcknight@instructure.com>
QA-Review: Tucker Mcknight <tmcknight@instructure.com>
Product-Review: Alexis Nast <alexis.nast@instructure.com>
why: when client credentials is attempting to decode a jwt and the body
that has been returned is not JSON (ie. html) we were just returning
the same error as if the jwt signature was bad which was not helpful.
fixes INTEROP-8220
flag=none
test plan:
there has been a change pushed since this ticket started that causes a
return of "JWT signature invalid" instead of the html we were getting
but that is still not quite right, so these steps will show the old,
current, and new output.
- Make sure your 1.3 dev key uses a public jwk url instead of a
public jwk (http://lti13testtool.docker/credential_id/1/public_jwk).
- In the test tool run `dcr web rake jwt:access_token CLIENT_ID=<YOUR_DEV_KEY>`
Current master branch should error with 400 and "JWS signature invalid".
- If you remove the `JSON::ParserError` from the rescue on
asymmetric_client_credentials_provider.rb:72, it will return an HTML
error page (as shown in this ticket).
- When you cherry-pick this current change it will error with 400 and
"Invalid JSON" which is the true error.
Change-Id: I940e21e9e596f59736c99d972d0a7868715dad11
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327388
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Xander Moffatt <xmoffatt@instructure.com>
QA-Review: Xander Moffatt <xmoffatt@instructure.com>
Product-Review: Alexis Nast <alexis.nast@instructure.com>
closes OUT-5896
flag=none
test plan:
- test are suficcient and pass in Jenkins
Change-Id: I65ed18d8b4cc3b3f45de5fecb7ff917696166de6
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327695
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Martin Yosifov <martin.yosifov@instructure.com>
QA-Review: Martin Yosifov <martin.yosifov@instructure.com>
Product-Review: Kyle Rosenbaum <krosenbaum@instructure.com>
fixes LF-732
flag=none
Test Plan:
-Go to files, preview media
-Verify Info button has aria-expanded false
-Open info button (mouse, keyboard, screenreader)
-Verify Info button has aria-expanded true
Change-Id: I0d283192acaf96dc8da3ffa65d26fa1c3dbd6177
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327821
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Mysti Lilla <mysti@instructure.com>
QA-Review: Mysti Lilla <mysti@instructure.com>
Product-Review: Jacob DeWar <jacob.dewar@instructure.com>
flag=react_discussions_post
flag=discussion_create
refs VICE-3749
previous commit missed a not sign
this commit fixes it
along with adding a sad path
and a happy path test
test plan:
- bundle exec rails c
- get a course
- @course.allow_student_anonymous_discussion_topics = false
- @course.save!
- as a teacher, verify that you can create an
anonymous discussion in the new discussion create page
- as a student, verify that you do not see anonymous
options on discussion create,
and you cannot create an anonymous discussion via graphql
(feel free to not test this as the spec does this)
Change-Id: Iecc74b2dfc32d67dd794d2c59ff50c7b4368cb0d
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327790
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jason Gillett <jason.gillett@instructure.com>
QA-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
Product-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
Refs FOO-3190
Refs FOO-3708
flag=none
[fsc-max-nodes=30] [fsc-timeout=60]
[pin-commit-multiple_root_accounts=03b5f961bbaa28af3d43b0a6a2ab072654cc6468]
Uprevs InstUI and addresses all post-uprev tasks. Also now that
InstUI is fully TypeScript, a bunch of type errors appeared
which needed to be addressed.
NOTE:
This is an amalgam of g/314136 and g/326557 which will get abandoned
once this passes Jenkins and is merged.
It builds against the commit of MRA that will have to merge
concurrently with this.
Still to do: theme -> themeOverride which is a separate commit
off of this one that is ready to go.
Test plan:
* cross your fingers
* (this will need some extensive review before merging)
Change-Id: I860c3dc04d34237e32aeaa138f6c377a016ceeae
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327683
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Aaron Shafovaloff <ashafovaloff@instructure.com>
Reviewed-by: Paul Gray <paul.gray@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Charley Kline <ckline@instructure.com>
Product-Review: Charley Kline <ckline@instructure.com>
Closes QUIZ-12124
flag=none
Test Plan:
- Make a request to fetch an active course without the
global_id include:
```
/api/v1/courses/:id/?include[]=lti_context_id
```
- Validate the response does not include a global_id
field
- Make a request to fetch an active course with the
global_id included:
```
/api/v1/courses/:id/include[]=global_id
```
- Validate global_id of the course is included in the
new global_id property of the response body
Change-Id: Ica8bfc830c52b3515821d5eb3820d83eb1fc93a8
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327316
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Mark McDermott <mmcdermott@instructure.com>
Reviewed-by: Stephen Kacsmark <skacsmark@instructure.com>
QA-Review: Mark McDermott <mmcdermott@instructure.com>
Product-Review: Weston Dransfield <wdransfield@instructure.com>
closes OUT-5895
flag=outcome_alignment_summary_with_new_quizzes
Test plan:
- Start Canvas, Outcomes-Service, Quiz LTI and Quiz API
- Create course with course outcome and add account outcome
- Enable "New Quizzes included on Outcome Alignment Summary Tab FF"
- Create new quiz, add quiz item and align course outcome to both
the quiz item and the quiz
- Create item bank with bank item, align account outcome to bank
item and add the item bank to the new quiz
- Click on Alignment Summary tab and verify that course outcome
displays Alignments: 2 and account outcome Alignments: 1
- Expand description of account outcome and verify that it
displays the alignment to the bank item
- Expand description of course outcome and verify that it
displays the alignment to the quiz item
Change-Id: Iec246d88dc21fd55b051f0c43c3c9816e92cb5f8
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327646
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Kyle Rosenbaum <krosenbaum@instructure.com>
Reviewed-by: Dave Wenzlick <david.wenzlick@instructure.com>
QA-Review: Dave Wenzlick <david.wenzlick@instructure.com>
Product-Review: Kyle Rosenbaum <krosenbaum@instructure.com>
refs VICE-3749
flag=react_discussions_post
flag=discussion_create
IN FOLLOW_UP COMMITS:
- add is_author_anonymous e2e functionality
- add e2e tests
NOTE:
- i found that we returned a 500 when creating a discussion
in a group context instead of 400 in our REST API
this commit fixes that issue (see new controller tests)
- i also deleted redundant env vars
TEST PLAN:
- turn on discussion_create and react_discussions_post
feature flags
- as a teacher create a fully anonymous discussion
- verify it saves and works as fully anonymous
- now, create a partially anonymous discussion
- verify it saves and works as partially anonymous
- create a non-anonymous discussion
- verify it saves and works as a non-anonymous discussion
LEGACY TEST PLAN:
- use rest api to test what is in the controller tests
or just code review the controller tests
Change-Id: Ida859c47c0c0d862f008278f56fb3f381ca7824d
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327459
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jason Gillett <jason.gillett@instructure.com>
QA-Review: Drake Harper <drake.harper@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
Product-Review: Caleb Guanzon <cguanzon@instructure.com>
When the new decaying average FF and Account Mastery scales is
enabled, the default calculation method was being stored as
weighted_average. This is incorrect and should be saved as
standard_decaying_average.
closes OUT-5897
flag=outcomes_new_decaying_average_calculation
test plan:
- tests pass in Jenkins
Change-Id: I172e320b95d462fafba943313fac17f2261a03c4
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327650
Reviewed-by: Kyle Rosenbaum <krosenbaum@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Jason Anderson <jason.anderson@instructure.com>
Product-Review: Kyle Rosenbaum <krosenbaum@instructure.com>
closes INTEROP-6659
flag=none
As detailed in https://github.com/rails/rails/issues/43466, the default
behavior for parameters in a route path is:
1. disallow dots, slashes, and question marks when parsing the request
URL, so that we don't greedily include these characters (particularly
slashes) in the parameter:
- example: we don't want "/courses/123/enrollments" to be matched by
route "/courses/:course_id" (with "123/enrollments" being
picked up as course_id); it will only be matched by
"/courses/:course_id/enrollments")
- example: if the request URL "/courses/123.txt/enrollments", the
parsing stops at the "." character, so course_id will be 123 and
rails will parse "txt" as the "format"
2. no constraints are enforced when constructing a path/url with a helper.
The helper will escape these special characters in the parameter
- example: courses_path(course_id: "a/b") will be "/courses/a%2Fb"
In our API routes we want to allow dots in the parameter, so
we use the "constraints" option when creating a route. This lets us
override that default regex (the one which disallows dots, slashes, and
question marks) with one that just disallows slashes and question marks.
Using "constraints" has the following effects:
1. rails uses the regex given to parse the request URL.
- example: we use a regex (ID_REGEX) conceptually similar to just
"[^/?]+" (it also disallows ids ending in '.json', but that's
irrelevant) so a route "/courses/:course_id" would:
- match "/course/123.txt" with "123.txt" being the course_id
- would not match "/course/123/foo" (would not greedily get
"123/foo" as course_id)
2. however, using constraints also has the unwanted effect of erroring
whenever we try to use a rails helper to construct the routing with a
rails helper.
- example: courses_path(course_id: "a/b") now errors, saying "a/b"
does not meet our constraints regex. We want it to return
"/courses/a%2Fb", as this is a working path with "a/b" as the
course_id.
As detailed in [this comment](https://github.com/rails/rails/issues/43466#issuecomment-1694140836),
`constraints` is used in two places, corresponding to the effects listed
in (1) and (2) above. This commit overrides the `requirements` method,
buried deep in an ActionDispatch (rails routing) object hierarchy, to
disable effect 2 (the checking of constraints when constructing paths
using helpers). The request URL parsing (effect 1) is unaffected.
The usage of the `constraints` for the two effects can be seen in
actionpack-7.0.7.2/lib/action_dispatch/routing/route_set.rb:163:
ast.requirements = @requirements
@path = Journey::Path::Pattern.new(ast, @requirements, JOINED_SEPARATORS, @anchor)
In this commit I am effectively removing our ID_REGEX constraint from
the @requirements passed in to Journey::Path::Pattern.new().
I explored some other avenues such as modifying the route immediately
after creating it with the ID_REGEX constraint in `route()`, but the
call to super() doesn't return the latest route, so to get at the route
I have to do something like `instance_variable_get(:@set).routes.last`
Test plan:
- check enrollments API endpoint works when given a SIS ID with an
(escaped) slash. You can also try question marks (escaped) and dots
(unescaped). Example (sis_course_id "a/b?c.d"):
/api/v1/courses/sis_course_id:a%2Fb%3Fc.d/enrollments
- check another endpoint where id is the last path prefix -- that it
parses correctly the escaped slash, and you can generate a url with a
slash
- for parsing, you can check the above URL minus "/enrollments"
- for generating: from a rails console, you can use something like
Rails.application.routes.url_helpers
.api_v1_audit_course_for_course_path \
course_id: "sis_course_id:#{Course.last.sis_source_id}"
You can also go to the returns URL to make sure it works
Change-Id: Ifaade757636065a43d078067f4ff04bd25dde383
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326718
Product-Review: Evan Battaglia <ebattaglia@instructure.com>
Reviewed-by: Xander Moffatt <xmoffatt@instructure.com>
QA-Review: Xander Moffatt <xmoffatt@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
flag=discussion_create
closes VICE-3751
Test Plan
1. Create a new discussion topic with the
1a "must respond before viewing other reply" option
2. Verify that the newly created discussion topic respects the option
Note, editing the newly created topic won't accurately show this setting
Change-Id: I64a76352b5ec04faf14c35a97e2c860dc326776b
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327487
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Omar Soto-Fortuño <omar.soto@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
Product-Review: Jason Gillett <jason.gillett@instructure.com>
and apply Rails/SelectMap and Rails/RedundantActiveRecordAllMethod
the offenses in User were manually fixed to maintain sharding
correctness
[skip-stages=Flakey]
[skip-crystalball]
Change-Id: I96f877ee8474655bd62a149f3aa54b312d38a5e4
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327334
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Build-Review: Cody Cutrer <cody@instructure.com>
closes FOO-3326
flag=temporary_enrollments
test plan:
- create an enrollments sis csv file with a temporary enrollment
- import the file and process the data (ensure jobs are running)
- verify that the enrollment is created with the correct
temporary_enrollment value
Change-Id: I8fbbd4860394f5a96989fb5d0136175e4aa47795
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327516
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Michael Hulse <michael.hulse@instructure.com>
QA-Review: August Thornton <august@instructure.com>
Product-Review: August Thornton <august@instructure.com>
fix a bug for points-based assignments where they were being rounded
incorrectly due to score_to_grade giving a score with 2 decimal
points of precision when only one should be supported for points
based grading. now the score_to_grade method will incorporate the
points-based grading scheme's scaling factor when calculating the
raw score out of 100 so that it stays at 1 decimal place of precision
when being converted to points.
closes EVAL-3318
flag=points_based_grading_schemes
test plan:
- enable points based grading schemes
- create a course to use a points based grading scheme that
uses whole numbers. the default one works well
- create an assignment that uses letter grade for the grading type
and choose the same points scheme, and set the assignment points
to the highest number of points allowed in the scheme
(4 if using default scheme)
- grade the assignment with a letter using the drop down in the
traditional gradebook, leaving all other assignments
ungraded
- look at the assignments subtotal and the total grade text
- verify that for the numerical grade, it shows 0.1 less than
the next higher scheme's lower bound (i.e. if you chose a
B, it should show 2.9)
- verify that it does this for all of the values B, C, and D, and
for A it gives them a 4 or the highest points possible
- go to the student grades page and verify that the total grade
is the same as the total grade in the traditional gradebook
Change-Id: I6577eecbc3e0135c86302afc8edde039f6444ff6
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/325518
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Derek Williams <derek.williams@instructure.com>
QA-Review: Derek Williams <derek.williams@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
List overrides that apply to a module, including the ids and names of
students/sections that are targeted by the override.
closes LF-651
flag = differentiated_modules
Test plan:
- In a course, create a module
- Create some assignment overrides for the module targeting both
sections and students (see
module_assignment_overrides_controller_spec lines 29-34)
- GET
/api/v1/courses/:course_id/modules/:module_id/assignment_overrides
- Expect a list of overrides with section/student names and IDs
- Make the request as a student
- Expect unauthorized
- Make a request with bad course or module IDs
- Expect 404
- Disable the flag and make the request
- Expect 404
Change-Id: Ifdc812812734dcf58c573775cbb92ad21e4131c0
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327379
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Jackson Howe <jackson.howe@instructure.com>
disable grade input in the enhanced individual gradebook when an
assignment is in a closed grading period
closes EVAL-3361
flag=enhanced_individual_gradebook
test plan:
- create a grading period set with one grading period that is in the
past and one that is currently active
- have two assignments with one due date lying in the past grading
period and one lying inside the active grading period
- as a teacher, not administrator, go the individual enhanced gradebook
and select the assignment that is in the past grading period
- verify that the main grade input is disabled, the submission details
grade input and button are disabled
- verify that in the assignment information section, the default grade
and curve grade buttons are disabled and have a message associated
with each
- change the assignment to be in the active grading period and see that
the buttons and inputs are all enabled
- as an administrator, or root account, verify that regardless if the
assignment is in the past or active grading period, the buttons and
inputs are all enabled
Change-Id: I6a9257979d0af0b04d888e4215fc25291b712b30
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/325708
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Spencer Olson <solson@instructure.com>
Reviewed-by: Cameron Ray <cameron.ray@instructure.com>
QA-Review: Rohan Chugh <rohan.chugh@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
fix where observers with concluded enrollments are unable to view
grades of linked students who are also concluded
closes EVAL-3319
flag=none
test plan:
- have a course with an enrolled student and an observer linked to that
student
- conclude the enrollment for both the observer and the student
- go to Prior Enrollments and act as the observer
- go to the grades page and see that it does not give the unauthorized
error and instead shows the grades page for the student
Change-Id: If6bd9e250f2bb02f4d1449f65803bd6a2e1f40ee
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/325927
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Jackson Huang <jackson.huang@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
Reviewed-by: Spencer Olson <solson@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
flag=restrict_quantitative_data
fixes VICE-3776
Test Plan
1. go to course settings and turn on RQD
2. Refresh the page
3. Verify that each course settings tab appears correctly
Change-Id: I588a3c9b6536b9d45ef32ede0b6ba81c20730571
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327455
Reviewed-by: Caleb Guanzon <cguanzon@instructure.com>
QA-Review: Chawn Neal <chawn.neal@instructure.com>
Product-Review: Jason Gillett <jason.gillett@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
closes LF-666
flag=none
test plan:
- in a rails console, find an assignment
- ensure that when the set_type is "Course", unassign_item
cannot be true
- run assignment.assignment_overrides.
create!(set: assignment.context, unassign_item: "true")
- the override should fail to create
- ensure that the "Course" set_type can otherwise be created
- assignment.assignment_overrides.create!(set: assignment.context)
Change-Id: Ica363c4ee387bc383d61ab882d6bd5ac7e26d4bf
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327131
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jackson Howe <jackson.howe@instructure.com>
QA-Review: Jackson Howe <jackson.howe@instructure.com>
Product-Review: Sarah Gerard <sarah.gerard@instructure.com>
fixes LF-720
flag=none
Test Plan:
- Create several recurring course calendar events
- Export the course and import it into another
- Check that the recurring events made it correctly
to the destination course
- Try the same with Blueprint Syncs and Course copies
- Ensure the recurring events are properly linked in
their destinations
Change-Id: I16297906bcabc7c23620f6cf4467baecb37f9615
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327058
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
Reviewed-by: Mysti Lilla <mysti@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Luis Oliveira <luis.oliveira@instructure.com>
closes OUT-5873
flag=outcome_alignment_summary_with_new_quizzes
Test plan:
- Start Canvas, Outcomes-Service, Quiz LTI and Quiz API
- Create course and enable "New Quizzes included on
Outcome Alignment Summary Tab FF"
- Add or Create at least 26 outcomes in the course
- Create new quiz and align all outcomes to the quiz
- Select Alignment Summary Tab and verify that that it
displays all aligned outcomes (scroll down until all
outcomes are loaded)
- Expand the outcome description of random set of aligned
outcomes and verify that it displays the new quiz alignment
- Filter outcomes "With Alignments", search for outcomes,
expand the descriptions of a random set of outcomes returned
from search and verify that it displays the new quiz alignment
Note: OS API returns up to 25 results per page; that's why
we need 26 outcomes to verify that AS supports pagination
Change-Id: I80d8bb5c173eae0be986b4aae1d82aa056775b04
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326973
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Wilmer Corrales <wilmer.corrales@instructure.com>
QA-Review: Angela Gomba <angela.gomba@instructure.com>
Product-Review: Kyle Rosenbaum <krosenbaum@instructure.com>
refs VICE-3777
flag=student_grade_summary_upgrade
Test Plan:
- create a custom status
- assign a submission to the new status
- query the submission in gql with the customGradeStatus field
> should show name of custom status
Sample Query:
query MyQuery {
legacyNode(_id: "1019", type: Course) {
... on Course {
id
name
_id
assignmentsConnection {
nodes {
_id
name
submissionsConnection {
nodes {
_id
id
customGradeStatus
}
}
}
}
}
}
}
Change-Id: I4658a23aa666b57e376e8957ac65426034c15672
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327273
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jason Gillett <jason.gillett@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
Product-Review: Drake Harper <drake.harper@instructure.com>
[skip-stages=Flakey]
[skip-crystalball]
and apply updated copys (RSpec/Eq and RSpec/MetadataStyle, and one
instance that the split RSpec/SpecFilePathSuffix caught)
Change-Id: I3872458f35b791f1ce3f8108a2aaf4fff2cfd612
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327204
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Isaac Moore <isaac.moore@instructure.com>
Build-Review: Isaac Moore <isaac.moore@instructure.com>
Build-Review: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
There are cases where an incoming reply to a canvas message
has html that is too long when the plain text content is not too long.
Submission and inbox messages do NOT use the HTML at all
Discussion entry replies can use it, but if it is nil, then it defaults to
use the plaintext over the html.
example in discussion entry reply_from
if opts[:html]
message = opts[:html].strip
else
message = opts[:text].strip
message = format_message(message).first
end
This should allow our users to send messages even if they have an
email signature that contains lots of html
refs VICE-3773
flag=none
Test Plan
1. Verify specs
2. Once deployed to an environment with email setup do:
2a. Send a message that contains html that is longer than 64kb
2b verify the message sent in canvas but only with plaintext contents
Change-Id: If1d90e8e63c9d333f005827839b5d2aaa0a1d4cb
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327236
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Chawn Neal <chawn.neal@instructure.com>
QA-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
Product-Review: Sam Garza <sam.garza@instructure.com>
flag=none
fixes VICE-3690
Test Plan:
- Create a course.
- Create 1000 discussion topics for it.
- go to the discussion topics index.
-- look at the network request.
-- you should see 10.
in a request it will have 100.
Notes:
- increase discussion per page from 50 to 100.
- now per page propogates on BE and FE.
Change-Id: Ib018a9b0652839f2b7a7dc93a48b015852185b28
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327189
Reviewed-by: Omar Soto-Fortuño <omar.soto@instructure.com>
Product-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
In the planner, we test if a user has access to an account context
by getting a list of the account IDs they're requesting and a list of
account calendar IDs they have access to. If an account ID appears
in the first but not the second, we run additional permission checks
(which most non-admin users won't pass). However, the IDs that the
user passes are transposed into local or global IDs relative to the
user's shard, while the account calendar IDs were previously relative
to the domain root account. Thus, if a user was requesting access
to a calendar on a different shard than the domain root account (but
also on the same shard as the user themself), we'd be comparing
local to global IDs and the check would fail. This commit transposes
the enabled account calendar IDs to be relative to the user's shard
to enable proper comparison of IDs.
flag = none
closes LF-570
Test plan:
(Requires trust setup)
- Enable the root account calendar on shard A
- Enroll a shard A user in a course on shard A and in a course on
shard B
- Visit the calendar as that user on shard B's domain
- Subscribe to shard's A root account calendar
- Expect no errors (specifically, the planner items request should
return a 2xx response)
Change-Id: I2fb572e342633805fa0d017041eb5f032f247eef
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327180
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Jackson Howe <jackson.howe@instructure.com>
still very much a prototype
test plan:
- install pgvector extension
(i.e. `brew install pgvector` or your operating system's
package manager)
- run db migrations and verify the "vector" extension
gets enabled
- set up OpenAI API key via `bin/rails credentials:edit`
and add
smart_search:
openai_api_token: <...>
- enable the smart_search feature flag in an account
- in a course under that account, create some wiki pages
with nontrivial content
- as a user who can see those pages, using the magnifying
glass that appears in the global nav, search for things
(by ideas and concepts rather than just keywords)
- it should find results
limitations:
- lots, please refer to the ADV-22 epic for next steps
flag=smart_search
closes ADV-21
Change-Id: I4a6cf4bc98cb144707df156baf143c3f9b70acdf
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/325880
Build-Review: Cody Cutrer <cody@instructure.com>
Migration-Review: Cody Cutrer <cody@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Zach Pendleton <zachp@instructure.com>
QA-Review: Zach Pendleton <zachp@instructure.com>
Product-Review: Zach Pendleton <zachp@instructure.com>
add pagination and search bar to peer review page in the teacher view
in order to fix page timeout when there are many peer reviews
closes EVAL-2762
flag=none
test plan:
- have a course with over 10 students and a peer review assignment
- as the teacher go to the assignment peer review page
- see that there are only 10 students on each page and the pagination
works
- use the search bar and enter search keywords
- see that page displays names relevant to the search keyword
Change-Id: Iaf6e2c81b8699fb4291b1ac6713b3004bc278f80
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326958
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Derek Williams <derek.williams@instructure.com>
Reviewed-by: Jackson Huang <jackson.huang@instructure.com>
QA-Review: Christopher Soto <christopher.soto@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
not that we really need to change, but it serves as an example for future
migrations
Change-Id: Ie1a1975311c81b0c145c17af46e57e604a01eca5
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327026
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jackson Howe <jackson.howe@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Build-Review: Cody Cutrer <cody@instructure.com>
Migration-Review: Cody Cutrer <cody@instructure.com>
refs AE-76
flag=none
test plan:
- secrets are read from Vault
- URL is read from Consul
Change-Id: Ie8fc4da260a36cab6446fcc15ab951a18df1c106
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326917
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Isaac Moore <isaac.moore@instructure.com>
Product-Review: Isaac Moore <isaac.moore@instructure.com>
flag=react_discussions_post
closes VICE-3706
Test Plan
1. Create a new discussion Entry
2. Verify that the discussion_entry_created event contains context info
2a. IF you don't want to set up liveEvents to QA:
2b. You can put a byebug on post_event in live_events.rb
2c. create a new discussion entry on react discussions
2d. Verify that the materialized_context contains the course context
Change-Id: I41c5170d3a75a1c93641e0dd027bdddba44b2d48
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327017
Reviewed-by: Drake Harper <drake.harper@instructure.com>
Product-Review: Drake Harper <drake.harper@instructure.com>
QA-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
This change adds the ability to filter the user search results by
temporary enrollment recipients and providers, or both. Later we will
identify the temporary enrollments in the search results by adding a
temporary enrollment icon to the user list rows. This will come in the
form of a provider or recipient specific icon.
closes FOO-3327
flag=temporary_enrollments
test plan:
• head on over to /accounts/self/users
• with the temporary enrollments FF enabled, you should see new
filter option checkboxes for temporary enrollments recipients and
providers
• in order for the temporary enrollments filters to work, you must
also have some temporary enrollment recipients and providers to
test with
• the filtering will work in conjunction with the existing search
filters, so you can filter by temporary enrollments and other
filters at the same time
• with the feature flag disabled, you shouldn't see the filter
checkboxes for temporary enrollment recipients and providers
Change-Id: I1da0cda2a8968982a3401efaf9f5bd4122463830
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327057
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Michael Hulse <michael.hulse@instructure.com>
QA-Review: August Thornton <august@instructure.com>
Product-Review: August Thornton <august@instructure.com>
fixes LF-731
flag=none
Test plan
- Specs pass
Change-Id: I5e0e5a2ddd0ae1703312d8ef9fb521717d7d6485
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327060
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Luis Oliveira <luis.oliveira@instructure.com>
Reviewed-by: Davis Hyer <dhyer@instructure.com>
QA-Review: Luis Oliveira <luis.oliveira@instructure.com>
QA-Review: Davis Hyer <dhyer@instructure.com>
Product-Review: Davis Hyer <dhyer@instructure.com>
fixes LF-656
flag=none
Test plan
- Set up a course with a page (or other rich content)
- Using the link insertion tray, insert a link to the
home page
- Copy the course
- Verify that the home page link you made points to
the new course after the course copy
- If you want, you can also export the course and
make sure that the link is a $CANVAS_COURSE_REFERENCE$
token and not a regular URL
Change-Id: Iffa27ea35b37e44bc33276baecb739d68b15b998
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326795
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jacob DeWar <jacob.dewar@instructure.com>
QA-Review: Jacob DeWar <jacob.dewar@instructure.com>
Product-Review: Mysti Lilla <mysti@instructure.com>
flag = none
closes LF-650
Test plan:
- Run the migration
- In a rails console, find a module and run:
`ao = context_module.assignment_overrides.create!
ao.assignment_override_students.create!(user: <a student>,
context_module: context_module)`
- Expect an AssignmentOverrideStudent to be created with a
reference to the module and the assignment override
- In psql, run `\d assignment_override_students` and observe that
the column is created along with the unique index and foreign key
Change-Id: I36d5d4250df09a67a2a27152bf6abc1c43d9f181
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326702
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Product-Review: Jackson Howe <jackson.howe@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Migration-Review: Cody Cutrer <cody@instructure.com>
Also updates the check constraint to allow AssignmentOverride to
have an assignment, a quiz, or a module. Changes the original
migration which created this check constraint to a predeploy to
match this migration (so that the 2 migrations are run in
chronological order on fresh databases).
flag = none
closes LF-649
Test plan:
- Run the migration
- In a rails console, find a module and run:
`context_module.assignment_overrides.create!`
- Expect an AssignmentOverride to be created with a
context_module_id pointing to the module
- In psql, run `\d assignment_overrides` and observe that the
column was created, the index was created, the foreign key
exists, and the check constraint also checks for a
context_module_id
Change-Id: I93195e28d082411ac43ed715f8eab5b42bd0094c
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326620
Reviewed-by: Cody Cutrer <cody@instructure.com>
Migration-Review: Cody Cutrer <cody@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Jackson Howe <jackson.howe@instructure.com>
Product-Review: Jackson Howe <jackson.howe@instructure.com>
created LF-731 to fix
Change-Id: I6f756f5f631f08f9fbd9d2d856ae9301e6805634
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327042
Reviewed-by: Robin Kuss <rkuss@instructure.com>
Reviewed-by: Luis Oliveira <luis.oliveira@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
QA-Review: Luis Oliveira <luis.oliveira@instructure.com>
Product-Review: Jackson Howe <jackson.howe@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
fixes LF-661
flag=none
Test plan
- Go to the syllabus page in a course
- Check the edit button and ensure it's actually
a button (and is read as such in a screenreader)
- Verify it reads something ("collapsed" in Safari)
to let you know the edit portion is not visible
Change-Id: I13236217018652bf807e135e984285a3236c8eb9
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326798
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jacob DeWar <jacob.dewar@instructure.com>
QA-Review: Jacob DeWar <jacob.dewar@instructure.com>
Product-Review: Daniel Sasaki <dsasaki@instructure.com>
closes LF-721
flag=calendar_series
test plan:
- click the + to create a new event
- set the date to a leap day (e.g. Feb 29, 2024
- open the frequency picker
> expect to see "Annually on Feb 29"
- click on custom and save
> expect to see "Annually on Feb 29, 5 times"
- submit
- when the api completes, click on one of the events
you just created
> expect the natural lang description to be correct
- click on one of the events and edit
- change the title and save
> expect the title to change on all events
(you can click on the month-year link at the top
of the calendar and type in a month-year
(eg. February 2028) to go there)
Change-Id: Ibd184e10597cf014ffa0ee877ae1911250330923
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327007
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Ed Schiebel <eschiebel@instructure.com>
flag = none
closes LF-713
Test plan:
(This is just regression testing the feature)
- Set up some account calendar events in the next week
- Go to the planner and make sure the events appear
Change-Id: Ida4d01ad72d4e0c67a55e6a67cc0ba6384d01464
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326918
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Jackson Howe <jackson.howe@instructure.com>
closes LF-714
flag = none
Test plan:
(This is just regression testing the auto subscription feature)
- Go to account calendar settings and make sure you can flip between
manual and auto subscription type
- Visit the calendar and expect to see events for auto subscribed
calendars, even if the user hasn't previously subscribed
Change-Id: I4a1d7188b15c6722457c77c1347668003aabb6c1
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326785
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Jackson Howe <jackson.howe@instructure.com>
Fixes FOO-3768
flag=none
Test Plan:
* Have a cross-shard version of a existing user that still has the
old lti_context_id. (see ticket for context)
* The new user does not have an LTI context id, create one
* If the existing user was deleted, it's lti_context_id is nullified
* Otherwise, the new user gets a new randomize (not hashed global_id)
LTI context ID.
Change-Id: Ibf5a35828051ace4101fe7bfade96f9085e39ab5
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326878
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
QA-Review: Jason Perry <jason.perry@instructure.com>
Product-Review: Jason Perry <jason.perry@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
created another ticket (LF-716) to clean this up
Change-Id: I0a739ce2e1c08b67dbc551d33a15d58a5852537a
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326934
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jackson Howe <jackson.howe@instructure.com>
QA-Review: Jackson Howe <jackson.howe@instructure.com>
Product-Review: Jake Oeding <jake.oeding@instructure.com>
closes EVAL-3359
flag=enhanced_individual_gradebook
test plan:
- create a course with a student and a teacher
- create at least three assignments
- put them in one assignment group
- create rules to drop certain assignments(maybe try a couple
different combos)
- go to the traditional gradebook and grade some of those
submissions and ensure some of the cells are labeled as dropped and
note which assignments are dropped for that student
- go to the enhanced srgb and ensure that the when selecting the
same assignments and that student, that the grading results shows
a message reading: 'This grade is currently dropped for this
student.'
- ensure when switching between student and assignments that the
message is hidden and displayed appropriately
Change-Id: I686be76a1de96c45cdc1cbe46f646a4b2dc289d4
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/325852
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Samuel Lee <samuel.lee@instructure.com>
Reviewed-by: Derek Williams <derek.williams@instructure.com>
QA-Review: Christopher Soto <christopher.soto@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
flags = new_quizzes_third_party_imports
Test Plan:
- Flag no longer appears.
Change-Id: I978c6872cd5f91b4b35e6cbf30b9f1a2e00b6d08
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326456
Product-Review: Marissa Pio Roda <marissa.pioroda@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Ferenc Marcsó <ferenc.marcso@instructure.com>
QA-Review: Ferenc Marcsó <ferenc.marcso@instructure.com>
If the delay posting at is in the future, the button should say 'save'
if the delay posting at is unchecked or in the past, the button should say 'publish;
fixes VICE-3704
flag=none
Test Plan
1. Create a delayed announcement
2. Verify that when you delay the announcement it changes the submit button from
2a publish to save
3. Edit the announcement
4. verify that on edit, the submit button says "save" if it is delayed
5. uncheck the delayed_post_at checkbox
6. verify that the submit button says "publish"
Change-Id: I224178247669becd392df538caabad6e0d69ea36
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326455
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Drake Harper <drake.harper@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
Product-Review: Sam Garza <sam.garza@instructure.com>
These started out as 3 separate commits, but the fixes
were intertwined and keeping them separate and stacked
on one another was proving to be too much of a hassle.
It should all work after this.
closes LF-629 LF-634 LF-632
flag=calendar_series
LF-629 "Update calendar correctly when editing recurring events"
Fixing this uncovered the same bug in the monthly view,
but it was just less noticable.
test plan:
- create a recurring event
- in an of the calendar views
- edit the title one of the events
- save any of the this, all, following options
> expect the events in the calendar to display the new title
- edit the start time of an event, save all and following
> expect the events in the calendar to show the start time
- try editing other stuff and expect it to work too
- edit an event in a series and shorten the series length
- save All Events
> expect the deleted events to be gone from the calendar
> expect them to be gone from the mini calendar
- change the title of 1 event and save "this event"
> expect just the 1 event to be updated
- change the title of the last event and save "this and following"
> expect just the 1 event to be updated
LF-634 "Stop FrequencyPicker changing when date on new event changes"
The root cause was not using the local state value for rrule, but
keying off the event.
test plan for 634
- in the calendar click on a date to create a new event
- in the modal, change the frequency
- then change the date
> expect the freq picker to change to reflect the new day
of the week
> unless it's a custom freq, in which case it remains the same
> this should work for weekly, monthly, and yearly frequencies
LF-632 "Update series events when changing calendars" test plan for
- have a teacher with a published course
- create an event series
- pick an event in the middle and change its calendar.
change just this event
- click on that event again, edit, submit, and choose all following
> expect all or all following events to reflect the new calendar
- click on each event
> expect the data in the popup to be correct
- switch to a different view
> expect the changes to the events to be reflected there too
Change-Id: Ie6ed678cf60922cd4660a3e75262b542d3e64a4d
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326203
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Juan Chavez <juan.chavez@instructure.com>
QA-Review: Juan Chavez <juan.chavez@instructure.com>
Product-Review: Ed Schiebel <eschiebel@instructure.com>
Some updates cause a series to be split in 2. The existing code
neglected to return the updated front half when that happened.
closes LF-702
flag=calendar_series
test plan:
- create a series of events
- change the start time of one in the middls and update
this and all following
> expect the edited event and those after to have the correct
description of the series
> expect the other events before the edited one to have an
updated description of the series
Change-Id: I374d43cd973704a6cedfbf47ac0a19a7b948b15a
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326719
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Ed Schiebel <eschiebel@instructure.com>
refactor the incomplete/complete select dropdown code into its own
component, which is associated with EVAL-3357
closes EVAL-3437
flag=individual_gradebook_enhancements
test plan:
1. the tests pass in GradingResults.test.tsx file
2. the grading functions work as intended
- incomplete/complete dropdown grading for the submission details
modal and main grade input
- the text input grading for the submission details modal and main
grade input
Change-Id: I35861e2d487c0c6b0bf08898773f75df0ad67d70
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326428
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Derek Williams <derek.williams@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
Reviewed-by: Christopher Soto <christopher.soto@instructure.com>
QA-Review: Jackson Huang <jackson.huang@instructure.com>
Product-Review: Cameron Ray <cameron.ray@instructure.com>
test plan:
- do a sis import using form data to provide AP parameters
but omit `attachment`
- you should get a 400 error with a "missing parameter" message
rather than an unsuccessful sis import that tried to
interpret the form itself as a sis batch
flag=none
closes FOO-3738
Change-Id: Ida7bc6e2bbde9e8db42965b94eda14cc00f900f2
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326466
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: August Thornton <august@instructure.com>
QA-Review: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
closes LF-644
flag = none
Test plan:
- Create/find a course with a few sections
- GET /api/v1/courses/:course_id/sections
- Expect to see all the sections
- Add ?search_term=<term> param
- Expect to see only sections whose name matches the term
Change-Id: I9598666bab193f277ab3c82236f471f58b7449ae
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326601
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Robin Kuss <rkuss@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Jackson Howe <jackson.howe@instructure.com>
This is a starting point for selective module release tests.
There are already a lot of module selectors available. I'm
creating new ones where it makes sense and using the old ones
if they are already available in the interest of re-use and time.
Closes LF-703
Test Plan: passes jenkins
Change-Id: I239382f5af6d5493a19c9f74b991a21c2a2a2ec9
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326669
QA-Review: Robin Kuss <rkuss@instructure.com>
Product-Review: Robin Kuss <rkuss@instructure.com>
Reviewed-by: Jake Oeding <jake.oeding@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
fixes LF-614
flag=none
Test plan
- It's probably best to have a file previewer
set up in your Canvas to test this.
Not sure how to do it without. There's a dev
preview server you can use. Let me know.
- In a course, upload a pdf or docx documet
- In a user's files, upload a pdf or docx document
- Somewhere in rich content in the course link
both documents
- Verify that with the default preview style
(Preview in overlay) you can see the document
preview for both the user file and the course
file
- Verify that as the course file, the download
link does not give you the file verifier
- You might also want to verify that the other
style of preview (Preview inline) is working
similarly
Change-Id: I0bb667f554af314d0ecc2d33190cd8ec277e17c1
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326102
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Product-Review: Mysti Lilla <mysti@instructure.com>
Reviewed-by: Jacob DeWar <jacob.dewar@instructure.com>
QA-Review: Jacob DeWar <jacob.dewar@instructure.com>
this commit adds the ability to save override statuses to the
process_bulk_update method used by the gradebook import process.
closes EVAL-3442
flag=custom_gradebook_statuses
test plan:
- setup a course with final grade overrides, a couple custom grade
statuses, and assign a final grade override to a student
- using a tool like Postman, make a PUT request to endpoint:
http://canvas.docker/api/v1/courses/<id>/update_final_grade_overrides
- You need to include the "Cookie" and "X-Csrf-Token" headers to the
request. You can find these from existing canvas api request in the
browser's network tab.
- add the following payload substituting the custom grade status and
student id with valid ids
{
"override_scores": [
{
"override_status_id": <id as string>,
"student_id": <id as string>
}
]
}
- verify in the gradebook grid that the override status color is set in
the grid for the student's override grade cell
- add the following payload to test changing the override status and
override score
{
"override_scores": [
{
"override_score": 100,
"override_status_id": <different id as string>,
"student_id": <id as string>
}
]
}
- verify in the gradebook grid that the override status color is set in
the grid for the student's override grade cell and the override score
is set to 100
Change-Id: Ifa8413f4e7df689e2b8ffd6771d5dba53b22d7c0
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326554
Reviewed-by: Spencer Olson <solson@instructure.com>
Reviewed-by: Rohan Chugh <rohan.chugh@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Spencer Olson <solson@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
allows the front end importer to recognize that there are
custom statuses for overrides that have changed from the current
import, showing which rows/columns changed. this is part 1/2, as
the next commit will add the last part which is saving those changes
closes EVAL-3441
flag=custom_gradebook_statuses
test plan:
- CANNOT BE QA'd UNTIL g/326378 IS MERGED
- go to a course with grading periods and for the gradebook filter,
select "All Grading Periods"
- add a custom status to a final grade override using the tray
- export the entire gradebook
- open a CSV editor and change the custom status you added to
something else and add another status for another student
- MAKE SURE THAT BOTH STUDENTS WHO WERE CHANGED ARE USERS WITH
LOGINS (otherwise they are not gradable students and the importer
does not recognize them)
- use the importer to import the CSV you just edited
- it should recognize the changes and show the columns and rows
that changed
- now do the same but for a single grading period, using the option
to export the current gradebook view instead of entire gradebook
- it should recognize the changes and show the columns and rows
that changed
- note: "applying" the changes or saving them will not work until
the next commit is merged
Change-Id: I081b05d63ac0a75d08ae23acb79388fcbf58ca4b
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326452
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Christopher Soto <christopher.soto@instructure.com>
Reviewed-by: Spencer Olson <solson@instructure.com>
QA-Review: Christopher Soto <christopher.soto@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
added save functionality to the custom statuses on the import
gradebook. this formats the body to be sent to the bulk update api
for final grade overrides, which is being implemented in a separate
ticket.
closes EVAL-3447
flag=custom_gradebook_statuses
test plan:
- wait for other dependent commits to be merged or cherry pick them
into this commit to fully test feature
- export a gradebook with a custom status on a final grade override
- change that custom status in the csv file to another valid
custom status
- import that gradebook csv
- the changes should be highlighted (from another commit) and
the custom status should be updated to the new value
- press save and view the network request that is sent to the update
final grades endpoint
- it should include the fields "override_status_id" and have the
matching id for the custom status that the override was changed to
- do the same for a course with grading periods and for a specific
grading period
- the request should have the grading period id in the body
- if the last commit of this feature has been merged, then it should
update the final grade override status in the traditional gradebook
Change-Id: I665bd75a25fb4b0c44c48db4a93fdf5354788d81
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326596
Reviewed-by: Spencer Olson <solson@instructure.com>
Reviewed-by: Christopher Soto <christopher.soto@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Christopher Soto <christopher.soto@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
this commit adds the ability for the backend to recognize custom
statuses in the gradebook import and save them to the database for the
use of the front end.
closes EVAL-3432
flag=custom_gradebook_statuses
test plan:
- setup a course with custom statuses on a final grade override
- import the gradebook with a column called "Override Status"
- make a change to a grade as well
- View the network request for endpoint
http://canvas.docker/courses/<courseId>/gradebook_upload/data
- Verify that the request contains a key in the students array called
override_statuses
- The override statuses should contain the current (old) grade status,
the new grade status, the grading period id, and the student id
- Add another import with the same custom status name as the old one
- Verify that the override_statuses key does not exist.
- Add one more import with no "Override Status" column
- Verify that the override_statuses key does not exist.
Change-Id: I86c35f16aaff300e9b4d2e549c6d773d3238f8b0
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326378
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Derek Williams <derek.williams@instructure.com>
Reviewed-by: Rohan Chugh <rohan.chugh@instructure.com>
QA-Review: Rohan Chugh <rohan.chugh@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
allow users to filter traditional gradebook by submissions that have
a custom status applied to them
closes EVAL-3434
flag=custom_gradebook_statuses
flag=enhanced_gradebook_filters
test plan:
- create custom statuses in the domain root account under the
"grading" tab after clicking site admin -> <domain root account
name>
- assign custom statuses to submissions in the gradebook
- verify all the custom statuses you created are listed in the filter
dropdown under the status section
- filter the gradebook by the custom statuses (apply filters ->
status -> <custom status name>)
- ensure that only the rows and columns that are necessary show up
in the gradebook (i.e. if an assignment has no submissions with
the custom status applied to them, the assignment column should not
show, and if a student has no submissions with the custom status
applied to them, the student row should not show)
- repeat for any other statuses you created
Change-Id: Ie6e5a1c7302f301fc217cb56d6568d85b5bc8348
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/325877
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Christopher Soto <christopher.soto@instructure.com>
Reviewed-by: Spencer Olson <solson@instructure.com>
QA-Review: Kai Bjorkman <kbjorkman@instructure.com>
Product-Review: Ravi Koll <ravi.koll@instructure.com>
our only use is for a hash that preserves insertion order, and Ruby's
Hash has done that for a _long_ time
Change-Id: Ia4e05b7022d75eea774be037f803d292b6ddacaa
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326470
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Build-Review: Cody Cutrer <cody@instructure.com>
refs VICE-3731
flag=student_grade_summary_upgrade
Test Plan:
- go to student grade summary page with
network inspector open
- inspect graphql request
- legacyNode > assignmentsConnection > nodes
- pick an assignment
> scoreStatistics field should show on assignment
Change-Id: If8156a8da2512325c2a3da6fb6a73003a90cccf7
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326241
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Kai Bjorkman <kbjorkman@instructure.com>
Reviewed-by: Derek Williams <derek.williams@instructure.com>
QA-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
Product-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
why:
* to avoid a weird situation where two LTI 1.3 developer keys
have the same domain/url and a tool for the wrong key is installed
in a closer context than the tool for the right key
closes INTEROP-8182
flag=lti_find_external_tool_prefer_original_client_id
test plan:
* follow instructions in the ticket:
* install two developer keys with the same domain
* install both tools from both keys in a course
* create some content using the first one, like an assignment
* then delete the first tool
* install a tool from the first key in the course's root account
* launch that content you created
* without this change it will launch using the second tool/client_id
* with this change and with the flag disabled it will do the same
* with this change and with the flag enabled it will correctly
launch using the first tool/client id
Change-Id: I31b8ad93b72eac7ba8847847cb76f15fc99ada07
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/325870
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Tucker Mcknight <tmcknight@instructure.com>
QA-Review: Tucker Mcknight <tmcknight@instructure.com>
Product-Review: Xander Moffatt <xmoffatt@instructure.com>