Commit Graph

57290 Commits

Author SHA1 Message Date
Xander Moffatt b336361ae8 fix CSP errors during LTI html redirect
why:
* doing an HTML meta-redirect or a JS redirect brings the CSP header
into play, which wasn't needed in a 302 redirect
* add the destination domain to the CSP header so that the redirect
doesn't fail
* allows us to keep testing if an HTML redirect solves INTEROP-8200
* also allows us to enable this setting for a single domain instead of
globally for better testing

refs INTEROP-8200
flag=none

test plan:
* install the 1.3 test tool in a course
* have multiple local shards
* in a test tool rails console, update the Platform's
authentication_redirect_endpoint to point to your second shard
* run
```
Setting.set("interop_8200_session_token_redirect/canvas.docker", "true")
```
in your canvas rails console (subbing your first shard's domain for
canvas.docker as neeeded) and restart your canvas containers
* launch the tool
* without this commit, the authorize_redirect will fail with a CSP error
* with this commit, the authorize_redirect will succeed and the
tool will launch

Change-Id: Ifd81fdbdd76fd97c67ff81a9e9b112679053aaff
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327027
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: Paul Gray <paul.gray@instructure.com>
2023-09-06 19:08:10 +00:00
Jackson Howe 066e923ada Skip failing syllabus specs
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>
2023-09-06 18:23:56 +00:00
Jacob Burroughs 02ade49370 Fix assorted attachment garbage collector bugs
Change-Id: Ia2cdaaf9159d19fb7827e4a59bc2327d393429d6
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/327038
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Jacob Burroughs <jburroughs@instructure.com>
Product-Review: Jacob Burroughs <jburroughs@instructure.com>
2023-09-06 18:10:13 +00:00
Mysti Lilla 1de1c2dbff Change syllabus edit to button with aria-expanded
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>
2023-09-06 16:43:07 +00:00
jake.oeding e1fffd87c1 make requests on update
refs LF-611
flag=differentiated_modules
qa risk: low

test plan:
-have the flag enabled and go to modules
-open the assign to tray and switch to 'settings'
-update name and / or lock until time
-click 'update module'
>in network tab, confirm the request is made with your updates
-refresh the page
>observe that your updates are reflected in the dom
-open the tray again for the module you updated
>confirm the updates you made flow through to the tray

Change-Id: I80d4f625608782e5873d933ee4abe58207dcad3f
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326776
Reviewed-by: Jackson Howe <jackson.howe@instructure.com>
QA-Review: Jackson Howe <jackson.howe@instructure.com>
Product-Review: Jake Oeding <jake.oeding@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
2023-09-06 16:34:39 +00:00
Cody Cutrer 289597dddb bundle update oj
Change-Id: If0d18da6a06bfc702274537e363d3acc1d6c43c8
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326815
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>
2023-09-06 15:24:04 +00:00
Cody Cutrer 9208f8ba2a bundle update selenium-webdriver
Change-Id: I0d3b919ae103c78520061b2f598eed6607d235c3
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326706
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>
2023-09-06 15:23:51 +00:00
Cody Cutrer c54e37ef36 remove several explicit dependencies
either gems that are not actually used directly by Canvas,
or are transitivie dependencies of another gem that's highly
unlikely to remove that dependency (i.e. no need to specify
inst-jobs or switchman when including switchman-inst-jobs;
it will always require those two)

Change-Id: Idc4f85e09158c9906da6b608ceb969815e535933
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326461
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>
2023-09-06 15:23:13 +00:00
Cody Cutrer 17b739ed86 use a distinct error message for too recent of successful login
refs AE-483

Change-Id: Icdc0c36a30e56f5d7fb6bdb4cff8460cf03beeec
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326797
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>
2023-09-06 15:23:01 +00:00
Cody Cutrer b5b14e7702 bundle update irb
Change-Id: I8a01f06f28c78d25ffeefc20103bf8881e22a570
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326956
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>
2023-09-06 15:22:48 +00:00
Cody Cutrer a4aa9cb129 bundle update pg
Change-Id: Ibbfbc6f4f502018bc9275c6fa9db63262b4852f5
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326957
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>
2023-09-06 15:22:38 +00:00
Cody Cutrer 1c4f8d67ea bundle update globalid
Change-Id: I1b3b02f90ada18ac367523383517e114196b4161
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326955
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>
2023-09-06 15:22:27 +00:00
Cody Cutrer 129ee390de fix federated attributes when email is provided, but it's empty
Change-Id: I6f6d3d6d1078a9c05ebf1ea0b4395ae96417884f
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326700
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>
2023-09-06 15:22:12 +00:00
Cody Cutrer 2e45d8207a add more info to bundle check bundle version mismatch message
make it match the mismatch message for other gems more closely

Change-Id: Iab0a4089eb7862bc24504041389f10345eecacbb
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326813
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>
2023-09-06 15:22:03 +00:00
Cody Cutrer c0e1ef1677 handle non-JSON responses when fetching public JWKs
fixes CANVAS-M3SP, CANVAS-M6MQ

Change-Id: Ibc7cb690e59d0155fa9a8b5c3312a19550d06256
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326961
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>
2023-09-06 15:21:50 +00:00
Cody Cutrer 7c8219f617 fix TurnitIn Error reporting for JSON responses
fixes CANVAS-KDBB

since the json Faraday middleware will parse them into a Hash,
instead of a string

Change-Id: I80dddcab4e4bc5fa5e3d726954bc85a4874de598
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326962
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>
2023-09-06 15:21:39 +00:00
Matheus e40760b957 Programatically add aria-label to calendar feed dialog
closes LF-659
flag=none

Test plan:
- With screenreader ON
- Navigate to calendar
- Open the calendar feed dialog
- Ensure the dialog has an accessible
  name, the same as it's title

Change-Id: Ieb344a6c3f46e231585a466f39f05f87bdace5ef
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326919
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Ed Schiebel <eschiebel@instructure.com>
QA-Review: Ed Schiebel <eschiebel@instructure.com>
Product-Review: Luis Oliveira <luis.oliveira@instructure.com>
2023-09-06 13:32:00 +00:00
Ed Schiebel 3ebcb96a72 Update calendar series natural language to handle leap day
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>
2023-09-06 13:31:00 +00:00
Matheus 4830425ba2 Refactor appointment group form time range for a11y
refs LF-660
flag=none

Test Plan:
- In Calendar, open the appointment gorup
  creation form modal
- Navigate the form with the screenreader
- Check that Time Range is called out whenever
  you navigate into either time range field.

Change-Id: I036c759188d08afd047d1ab7f9569a7df2e421a5
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326909
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: Luis Oliveira <luis.oliveira@instructure.com>
2023-09-06 13:07:20 +00:00
Matheus 1db1a41e73 Add high contrast border to calendar inputs missing it
refs LF-660
flag=high_contrast

Test plan:
- With high contrast ui ON
- Check that the following calendar modal forms have
  inputs with proper border contrast
  To-Do item creation form, assignment creation form,
  appointment creation form.

Change-Id: I07207efe5eef8e4b17e663cd45133d6473dbdee7
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326819
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: Luis Oliveira <luis.oliveira@instructure.com>
2023-09-06 13:06:38 +00:00
David Kalacska b2926d2a01 Add new feature flag for K20 Beta features
flag = none
refs EAX-228
test_plan = it's not needed here

Change-Id: I927f50a792ba2277d18f2cac59c364fc56d66459
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326753
Reviewed-by: Gabor Konstanzer <gabor.konstanzer@instructure.com>
QA-Review: Gabor Konstanzer <gabor.konstanzer@instructure.com>
Product-Review: Gabor Konstanzer <gabor.konstanzer@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
2023-09-06 08:03:13 +00:00
Jeremy Stanley 1c417062eb add explainer text for view_admin_analytics permission
test plan:
 - the "what it does" and "additional considerations" text should be
   visible in the permissions sidebar (see FOO-3701)

flag=view_admin_analytics
closes FOO-3787

Change-Id: I5e79ed80c3b65a79ce5c5e049237b268e8f1a7b3
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326916
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Charley Kline <ckline@instructure.com>
Reviewed-by: August Thornton <august@instructure.com>
Reviewed-by: Michael Hulse <michael.hulse@instructure.com>
QA-Review: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
2023-09-05 22:27:03 +00:00
Jackson Howe 1a96e8626e Remove account_calendars_planner_support flag
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>
2023-09-05 21:04:58 +00:00
Jackson Howe ead77d28c7 Remove auto_subscribe_account_calendars flag
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>
2023-09-05 21:04:21 +00:00
Jackson Howe 5a344b6f49 Speed up AccountTree specs
by replacing *byRole with *byText

flag = none

Test plan: specs pass

Change-Id: I4a2267caa451dfa42a686da2f6b245b7c68d1556
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326944
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jake Oeding <jake.oeding@instructure.com>
QA-Review: Jackson Howe <jackson.howe@instructure.com>
Product-Review: Jackson Howe <jackson.howe@instructure.com>
2023-09-05 19:27:18 +00:00
Jason Perry e4bf3c72a7 Handle duplicate lti_context_ids safely
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>
2023-09-05 18:44:33 +00:00
Jackson Howe ebba0962fd Don't compare array objects by reference
Change-Id: I06ad83188b53fb6d7c83ac3a54e8897d21625b22
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326925
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>
Reviewed-by: Jake Oeding <jake.oeding@instructure.com>
Reviewed-by: Aaron Shafovaloff <ashafovaloff@instructure.com>
2023-09-05 18:33:17 +00:00
jake.oeding ed4d54f869 skip autosave tests to save the postmerge builds
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>
2023-09-05 18:09:09 +00:00
Robin Kuss af9a4ae7b0 add more calendar recurrent event tests
Closes LF-605

Test Plan: passes Jenkins

Change-Id: Icfadcbe84b81ff3c9bac899789f7117ac736ff8b
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326644
Reviewed-by: Ed Schiebel <eschiebel@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Ed Schiebel <eschiebel@instructure.com>
Product-Review: Robin Kuss <rkuss@instructure.com>
2023-09-05 16:00:14 +00:00
Kai Bjorkman 249ae5937c identify dropped assignments in enhanced srgb
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>
2023-09-05 15:42:09 +00:00
Matheus 087a190a7b Fix appointment group form labels
refs LF-660
flag=none

Test plan:
- In Calendar, open the appointment group
  creation form modal
- Try out the checkbox labels and make ensure
  they toggle the checkboxes properly

Change-Id: I5e330dd603e19076bcd17e6ff69702a58e7d8304
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326820
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: Luis Oliveira <luis.oliveira@instructure.com>
2023-09-05 15:38:08 +00:00
Jeremy Stanley 13b00464df bump gergich for script/rlint
because of course there are three places for this (ノಠ益ಠ)ノ

Change-Id: Icc8e6dd9c4f35685a282af70162e1a911c9a6eca
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326821
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
2023-09-05 15:12:43 +00:00
Steve Kacsmark 2e4272aba1 Deprecate third part imports feature flag for now
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>
2023-09-05 15:11:50 +00:00
Jason Gillett 6e3ce2f950 Add willPublish condition to announcement create page
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>
2023-09-05 15:11:10 +00:00
Aaron Shafovaloff 792bfc8052 upgrade to typescript 5.2
test plan:
  build passes

flag=none

Change-Id: Ica9a47432508eeaff583ef8eaac87fbda97d84aa
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326902
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Derek Williams <derek.williams@instructure.com>
Reviewed-by: Omar Soto-Fortuño <omar.soto@instructure.com>
QA-Review: Aaron Shafovaloff <ashafovaloff@instructure.com>
Product-Review: Aaron Shafovaloff <ashafovaloff@instructure.com>
2023-09-05 14:10:29 +00:00
Jenkins 25ff5de278 update nn translation
Change-Id: I813f06ae6eca23311888de9723bca98ed7e34005
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326882
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
2023-09-05 05:48:48 +00:00
Ed Schiebel 0c46439c18 Fix 3 recurring event bugs
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>
2023-09-04 23:16:07 +00:00
Jeremy Stanley 4c62cdf652 bump gergich
to deal with :info offenses

Change-Id: I6dacd48079f15dd0bcfc5c37acd9097f52c105ad
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326818
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jacob Burroughs <jburroughs@instructure.com>
QA-Review: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
Build-Review: Jacob Burroughs <jburroughs@instructure.com>
2023-09-02 02:56:29 +00:00
AJ Esa 9fc81fc400 add asterisk for required new user and course fields
when adding a new course or user, the required input boxes have a red
border that disappears when you select the input field. this change
makes it so that there is a red asterisk that stays next to the
visual label for accessibility.

closes FOO-3761
flag=none

test plan:
- go to courses or people page
- select +course or +people button
- check that the asterisk shows next to the visual label for the
  required fields

Change-Id: Iaa9f021be450c6c51421d21c47c535bdca7c172e
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326613
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Ajmal Esa <ajmal.esa@instructure.com>
Product-Review: Ajmal Esa <ajmal.esa@instructure.com>
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
2023-09-01 21:22:38 +00:00
Omar Gerardo Soto-Fortuño 2f038a5d09 Use allRootEntries on DiscussionSubentries
closes VICE-3199
flag=react_discussions_post

test plan:
  - Specs pass.
  - No behavior change, current specs are enough.
  - Cursory testing of inline view.
  - Should load all entries associated to a root
      entry without executing multiple queries.

qa risk: low

Change-Id: Ic54f14173432735f3d29bb8bb4c36c47642d8c9a
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326695
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Drake Harper <drake.harper@instructure.com>
QA-Review: Jason Gillett <jason.gillett@instructure.com>
Product-Review: Omar Soto-Fortuño <omar.soto@instructure.com>
2023-09-01 19:03:23 +00:00
Jeremy Stanley 5532285bc6 don't give bad advice about add_replica_identity
g/325983 requires `add_replica_identity` to be in a separate
migration from the commit that creates the table, for
complicated DBA reasons. change the phrasing of the
Migration/RootAccount cop so it doesn't contradict the
newer Migration/SetReplicaIdentityInSeparateTransaction

test plan:
 - make a new migration that creates a table
   and does not do `add_replica_identity`
 - the cop should tell you to do that in a different migration
   and not after the `create_table` block in this one

flag=none
refs AE-443

Change-Id: Id37914399d40739e9fd8a72b90745c29d9e7cbda
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326791
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
2023-09-01 18:53:02 +00:00
Mysti Lilla 1383074a6c Make inherited caption languages show up in selector
fixes LF-616
flag=media_links_use_attachment_id

Test plan
- Set up a course with a media file
- Set up some captions on that media file
- Copy that course to a new course
- In the new course, delete the captions
- Reload the page and look at the list of
  captions
- The inherited captions should now show up
- Ensure you can select the same language
  as the inherited captions and create new
  captions

Change-Id: Iffdcd25c3923b986a0ef482ff255d61dc98a5948
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326729
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Luis Oliveira <luis.oliveira@instructure.com>
QA-Review: Luis Oliveira <luis.oliveira@instructure.com>
Product-Review: Mysti Lilla <mysti@instructure.com>
2023-09-01 18:03:39 +00:00
AJ Esa 0e22057343 darken close button in admin tab
darken the close button in the Admin tab of the Account Settings
page. the close button is also the same color whether on hover or
not to meet contract requirements.

closes FOO-3757
flag=none

test plan:
- go to the account settings page
- select the admin tab
- check that the "x" close button is dark enough to see with the
  contrast of page background

Change-Id: Ieb248efdc6ee848758a0207148e6a7fc6a5586c9
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326392
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
Reviewed-by: Michael Hulse <michael.hulse@instructure.com>
QA-Review: Ajmal Esa <ajmal.esa@instructure.com>
Product-Review: Ajmal Esa <ajmal.esa@instructure.com>
2023-09-01 17:46:55 +00:00
AJ Esa 31ad1e7f7e add aria-label pagination to pagination nav
closes FOO-3762
flag=none

test plan:
- go to courses or people page
- check that pagination nav element has an aria-label value of
  pagination

Change-Id: I67fd733aece47d5aa7aca60e75586c8e9505ea3f
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326480
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Michael Hulse <michael.hulse@instructure.com>
Reviewed-by: August Thornton <august@instructure.com>
QA-Review: Ajmal Esa <ajmal.esa@instructure.com>
Product-Review: Ajmal Esa <ajmal.esa@instructure.com>
2023-09-01 17:46:30 +00:00
AJ Esa 301593c196 change report names to row headers
for account settings admin tab, change the names of the reports
to be table header elements to make them row headers. this is so
screen readers can read them differently than the information in
the table, i.e., the td elements.

closes FOO-3758
flag=none

test plan:
- go to account settings page
- go to reports tab
- check that the report names in the table are <th> elements

Change-Id: I83dcf114dfc815662134200a292afdec63e4a4e1
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326474
QA-Review: Ajmal Esa <ajmal.esa@instructure.com>
Product-Review: Ajmal Esa <ajmal.esa@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Michael Hulse <michael.hulse@instructure.com>
Reviewed-by: August Thornton <august@instructure.com>
2023-09-01 17:46:17 +00:00
Ed Schiebel d49e4d267e Return all events when an update splits a series
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>
2023-09-01 17:02:45 +00:00
Samuel Lee dddc22a439 refactor incomplete/complete select dropdown code
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>
2023-09-01 16:20:06 +00:00
jake.oeding 0f5c22ae81 update npm version in dockerfiles
fixes error during build

Change-Id: I319634a1988d05bb29f19dee6b8a994e6814d6d2
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326773
Reviewed-by: Aaron Ogata <aogata@instructure.com>
Build-Review: Aaron Ogata <aogata@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Jake Oeding <jake.oeding@instructure.com>
Product-Review: Jake Oeding <jake.oeding@instructure.com>
2023-09-01 15:20:08 +00:00
Kai Bjorkman 369086d752 update grading standard api documentation
flag=none
closes EVAL-3316

Test Plan:
    - ensure example curl command completes without error

Change-Id: I4170a39ecb0124c78060a4d12f65f76bc784c18a
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326435
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Derek Williams <derek.williams@instructure.com>
QA-Review: Cameron Ray <cameron.ray@instructure.com>
Product-Review: Cameron Ray <cameron.ray@instructure.com>
2023-08-31 22:21:08 +00:00
Evan Battaglia 4eadab2fc5 fix race condition in postMessage forwarding
In the postMessage forwarders (both the "sibling iframe" and the RCE
one) we are currently storing the source window in a lookup table from
origin -> window, and using that to determine where the response should
be set to. If two tools use the same origin, then depending on timing,
it is possible for one to get the response message intended for the
other.

We can't forward the source Window in a postMessage, nor could I find
anything unique in the Window object to key off, but object equality
(===) works, so we can just keep the Window objects in an array and use
an index into that array in the forwarded postMessage.

closes INTEROP-8206
flag=none

Test plan:
- go to a page with the same tool e.g. the LTI 1.3 test tool) launched
  multiple times. Possibilities include:
  - RCE content with embedded tool launches
  - new assignment page with the tool in multiple placements that show
    up here
- add a console.log() statement right before the
  `targetWindow?.postMessage(message, targetOrigin)` line to log the
  windowId, targetOrigin, and targetWindow, in the code that handles the
  response message (index.ts), like this:
      console.log('forwarding message to',
      targetOrigin, sourceToolInfo.windowId)
- send some messages (e.g. {"subject":"lti.capabilities"}) from each
  tool launch iframe to the forwarder window (check the "Send to LTI Storage
  Target" option in the test tool). In the dev console, check that your
  logging shows a unique windowId is used for each source iframe. Also
  make sure that the response gets to the tool (you should see both the
  "messageSent" and the "messageReceived" object logged to the console)
- Run messages multiple times, varying which tool launch iframe you send
  from, and make sure exactly 1 windowId is used per tool launch iframe.
  (e.g., if you have 2 tool iframes, windowId will always be either 0 or
  1)
- add a similar logging statement in
  packages/canvas-rce/src/rce/RCEWrapper.jsx
  before the targetWindow?.postMessage(...) line, e.g.
      console.log('rce forwarding message to',
      targetOrigin, sourceToolInfo.windowId)
  note: since the RCE stuff is in a package, you may need to do a 'yarn
  install' followed by the normal asset building stuff for it to pick up
  the change
- in the RCE (e.g. the assignment edit page), launch the test tool and
  put `{"width":600, "height":600}` in the "iframe" box before sending
  back the content item. this should render a tool iframe inside the editor
- repeat the last step to add a 2nd tool iframe into the RCE content.
- as before, send some message from each tool to the PARENT (not
  forwarder) window ("Send to LTI Storage Target" option UNCHECKED)
  and check the console.log() output to see that it uses a different
  windowId for each tool iframe. Also make sure that the response gets
  to the tool (you should see both the "messageSent" and the
  "messageReceived" object logged to the console)
- if possible, test this in different browsers. due to cookie issues, it
  may be difficult to test locally except in Firefox, so test that we
  can identify windows by object equality (===) in different browsers
  with this test HTML page:
    <iframe srcdoc="<button onclick=&#34;window.parent.postMessage('hi', '*')&#34;>send</button>"></iframe>
    <iframe srcdoc="<button onclick=&#34;window.parent.postMessage('hi', '*')&#34;>send</button>"></iframe>
    <iframe srcdoc="<button onclick=&#34;window.parent.postMessage('hi', '*')&#34;>send</button>"></iframe>
    <script>
      const windowToId = (windowReferences, win) => {
        const existingIndex = windowReferences.indexOf(win)
        if (existingIndex !== -1) {
          return existingIndex
        }
        windowReferences.push(win)
        return windowReferences.length - 1
      }

      windowRefs = []
      window.addEventListener('message', e => console.log("msg from", windowToId(windowRefs, e.source)))
    </script>

Change-Id: I276912f46e6fd701da1821c7ff02b3011cf823d7
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/326284
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: Evan Battaglia <ebattaglia@instructure.com>
2023-08-31 21:03:41 +00:00