Commit Graph

1053 Commits

Author SHA1 Message Date
Rob Orton f7255e9b52 add integration_id to grade export
fixes GRADE-2229

test plan
 - export gradebook
 - it should work
 - set root_account to include integration_ids in gradebook
 - export gradebook
 - it should include integration_id
 - account grade export reports should also use account setting
 - import grade export that includes integration_id
 - it should import with out error

Change-Id: I7b5eb980492c3ee657e87df27217263c36615cb4
Reviewed-on: https://gerrit.instructure.com/196982
Tested-by: Jenkins
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
Reviewed-by: Keith Garner <kgarner@instructure.com>
Reviewed-by: Nathan Mills <nathanm@instructure.com>
2019-06-15 07:38:18 +00:00
Jeremy Stanley 2c58144a17 fix importing question groups that pick 0 questions
test plan:
 - create a quiz that includes a question group that picks 0 questions
   (either from a set of questions or a question bank)
 - copy the course
 - the copy should preserve the question group

fixes ADMIN-2724

Change-Id: If4a0197c307361b3cf1dce210fb6610c4ff05b0e
Reviewed-on: https://gerrit.instructure.com/197302
Tested-by: Jenkins
Reviewed-by: James Williams <jamesw@instructure.com>
QA-Review: Carl Kibler <ckibler@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
2019-06-14 22:49:38 +00:00
Brent Burgoyne 88fb288d64 drain live events queue before the process exits
closes PLAT-4550

test plan:
- tests pass
- this would be hard to manually qa, but if you want you could add a
  sleep to the live event async worker loop, do some stuff that
  queues events, ctrl-c the rails server, and watch the loggs for it
  to process the events before finally exiting.

Change-Id: I8c82b07ff5eec75cf51a307a2571f3780e75a216
Reviewed-on: https://gerrit.instructure.com/197276
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins
2019-06-12 05:25:25 +00:00
Rob Orton 0fb1f146e3 rename report helper
refs CORE-3011

test plan
 - specs should pass

Change-Id: Ic7ab02bf813698da8e8064dec9abb46b91e0be9f
Reviewed-on: https://gerrit.instructure.com/195560
Tested-by: Jenkins
Reviewed-by: Nathan Mills <nathanm@instructure.com>
QA-Review: Nathan Mills <nathanm@instructure.com>
Product-Review: Nathan Mills <nathanm@instructure.com>
2019-05-31 21:27:52 +00:00
Rob Orton 770b694f03 update current_line on master
fixes CORE-2819

test plan
 - running an account report on slave should work

Change-Id: Ic850b8ec68c4beb234e3c49438d317a659ddd11b
Reviewed-on: https://gerrit.instructure.com/195755
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins
2019-05-30 01:08:55 +00:00
Rob Orton c6e4765dde check workflow_state on enrollment.sis_psedonym
refs CORE-2976

test plan
 - enroll user via sis
 - delete login with sis id
 - run report
 - it should just use the active login

Change-Id: I023b4aa259dd06b83165be7e9478d2b712023f72
Reviewed-on: https://gerrit.instructure.com/194082
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins
2019-05-29 20:34:50 +00:00
Cameron Matheson 4ff40a8976 fix dynamo typo
Change-Id: I43f8e156206db35ac6fe90ae04b75271799db6c7
Reviewed-on: https://gerrit.instructure.com/193804
Tested-by: Jenkins
Reviewed-by: Rob Orton <rob@instructure.com>
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-05-24 20:39:53 +00:00
Ryan Shaw d6676fba80 Make sure if we treat data-* as html, it can be trusted
Fixes: CORE-2938 CORE-2937 CORE-2935 CORE-2933

We have a bunch of stuff in our code where we use data-whatever
attributes to tell our javascript what to do. and a few of those treat
whatever is in data-whatever as trusted html. The problem is that users
can save whatever data-* attributes in the content they save
in a rich text editor. So if they mimic the same classnames or ids as
elements we trust, they can exploit us. 

The fix is to still allow data-* attributes EXCEPT the ones we treat
as html. By filtering those out, we can treat them as trusted html.

Refs: SEC-2166 ADMIN-2376
This partially reverts ADMIN-2376 because instead of having to load all
tinyMCE to sanitize it on the client, if we treat it the same as all of
these other ones, we can just count on data-html-tooltip-title as coming
from us.

NOTE: in the future:
1. Don’t treat the Dom as the source of truth.
2. If you do, use an attribute like x-canvaslms-trusted-whatever
   because that will not be allowed through in our html sanitizer
   so we can know if that attribute is ever there on an element, 
   we put it there and not a user or hacker.

Test plan:
* Look at the repro steps on any of the attached jiras. 
* You should not be able to reproduce it
* there is an automated test fixture for each one that has been added
  To spec/fixtures/xss/

Change-Id: Idf77ac6d80518bfe02445f94942ac5f6802772dc
Reviewed-on: https://gerrit.instructure.com/194850
Tested-by: Jenkins
Reviewed-by: Clay Diffrient <cdiffrient@instructure.com>
QA-Review: Clay Diffrient <cdiffrient@instructure.com>
Product-Review: Clay Diffrient <cdiffrient@instructure.com>
2019-05-23 22:07:50 +00:00
Ryan Shaw 83eca54a7f Make i18n scope string file loading faster
by replacing $.extend(true I18n, {translations: …}), we can speed up
the amount of time we spend loading the i18n string files. 

From profiling, a non-trivial amount of the javascript run time was
Spent just in these calls to $.extend(true, …)

Test plan:
* in a prod build
* set your language to something non-english like spanish
* everything should still be translated the same as before
* pages should load a little faster, especially on low powered devices
  like mobiles

Change-Id: I9ac4a7b67cf14498ee1b972ba083db952ad7f314
Reviewed-on: https://gerrit.instructure.com/194234
Tested-by: Jenkins
Reviewed-by: Clay Diffrient <cdiffrient@instructure.com>
QA-Review: Clay Diffrient <cdiffrient@instructure.com>
Product-Review: Clay Diffrient <cdiffrient@instructure.com>
2019-05-23 21:17:58 +00:00
Rob Orton 73a538e37a update total lines before using for progress
Change-Id: Id0235902fca5dcf4b718a33dd18f9cc11cb8b5ce
Reviewed-on: https://gerrit.instructure.com/194665
Tested-by: Jenkins
Reviewed-by: Tyson Brown <tbrown@instructure.com>
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-05-22 20:00:55 +00:00
Rob Orton e927497be5 send report object to failed report
Change-Id: I35c90b8433d4ca3651a5ebf1cd7be59d411ca750
Reviewed-on: https://gerrit.instructure.com/194554
Reviewed-by: Tyson Brown <tbrown@instructure.com>
QA-Review: Tyson Brown <tbrown@instructure.com>
Tested-by: Jenkins
Product-Review: Rob Orton <rob@instructure.com>
2019-05-21 19:35:31 +00:00
Cameron Matheson 510f50090e log graphql mutations
closes GQL-57

Test plan:
  * run some mutations
  * without a config/dynamodb.yml, graphql queries/mutations should work
    as usual
  * set up a 'auditors' category in config/dynamodb.yml:
    * information about mutations should be recorded to the
      '#{auditors-prefix}-graphql_mutations' table

Change-Id: Ide0e3707f74488dfa896ddb97820956e5bdc8e27
Reviewed-on: https://gerrit.instructure.com/188460
Tested-by: Jenkins
Reviewed-by: Rob Orton <rob@instructure.com>
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-05-15 18:43:24 +00:00
Brent Burgoyne 4bafa316af add support for dynamodb
Change-Id: Idbc657569dc0872ac91cff21051000cfa57f3e8e
Reviewed-on: https://gerrit.instructure.com/188738
Tested-by: Jenkins
Reviewed-by: Rob Orton <rob@instructure.com>
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-05-14 22:56:47 +00:00
Rob Orton 128a4cb3cc use sis_pseudonym from enrollment if there is one
fixes CORE-2926

test plan
 - specs should pass

Change-Id: I0b349bc44aecffbcede7093b0689e686c49fe0bb
Reviewed-on: https://gerrit.instructure.com/192886
Tested-by: Jenkins
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
2019-05-14 15:18:40 +00:00
Rob Orton 9a60542753 don't cause error generating error
fixes CORE-2916

Test Plan
 - generate account report should work

Change-Id: I3b1ce90f98c70925d4b77de952007ef4e722b745
Reviewed-on: https://gerrit.instructure.com/192598
Tested-by: Jenkins
Reviewed-by: Cody Cutrer <cody@instructure.com>
Reviewed-by: Cameron Matheson <cameron@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
2019-05-08 22:07:51 +00:00
Rob Orton 4296381ded don’t try stuff on nil
fixes CANVAS-5DQZ - show_helper 133k
fixes CANVAS-4VFR - quizzes_controller 293k
fixes CANVAS-4VFT - oauth/providor 287k
fixes CANVAS-5T4G - oauth2_providor_controller 11k
fixes CANVAS-4VQF - context_modules_controller 13k
fixes CANVAS-4W6A - grades.html.erb 1k
fixes CANVAS-4SNC - discussion_entry 46k
fixes CANVAS-4VJY - dup of discussion_entry 16k
fixes CANVAS-4SYM - users_controller 51k
fixes CANVAS-4VRJ - quiz_submission_history 3.3k
fixes CANVAS-4Y92 - gmail 51k
fixes CANVAS-4VM8 - media_object 7.8k
fixes CANVAS-4VHB - quiz_submission_events 9.2k
fixes CANVAS-6WSZ - course.rb 5
fixes CANVAS-5SD6 - active_record 33
fixes CANVAS-6WYD - dup of active_record 1
fixes CANVAS-4VHG - collaborations_controller 24k
fixes CANVAS-6PFH - files/show 2.2k
fixes CANVAS-4VSR - pv4_client 14k

Change-Id: I12cf698c6930ef4674ecfee02bc341e3650ef7fc
Reviewed-on: https://gerrit.instructure.com/188120
Tested-by: Jenkins
Reviewed-by: Brent Burgoyne <bburgoyne@instructure.com>
QA-Review: Brent Burgoyne <bburgoyne@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-05-03 21:01:35 +00:00
Brent Burgoyne 238eb2f118 include ms precision for live event event_time
closes PLAT-3761

test plan:
- configure live events plugin setting to write to a local kinesalite
  stream
- make sure there aren't any errors writing to the stream

Change-Id: I88944ad3ad80ecaa18c6da3739b34b2551ba2366
Reviewed-on: https://gerrit.instructure.com/192000
Reviewed-by: Weston Dransfield <wdransfield@instructure.com>
QA-Review: Weston Dransfield <wdransfield@instructure.com>
Tested-by: Jenkins
Product-Review: Brent Burgoyne <bburgoyne@instructure.com>
2019-05-03 16:25:40 +00:00
Rob Orton 21c18fa1ee make reports tab load independently of settings
fixes CORE-2808

test plan
 - load settings page, it should work
 - load reports tab, it should work

Change-Id: I0616b4c2b23189a28a82360202fb1e4f5512892b
Reviewed-on: https://gerrit.instructure.com/189873
Reviewed-by: Ryan Shaw <ryan@instructure.com>
QA-Review: Ryan Shaw <ryan@instructure.com>
Tested-by: Jenkins
Product-Review: Rob Orton <rob@instructure.com>
2019-04-19 18:23:20 +00:00
Jeremy Stanley 528527a171 fix non-ASCII URI validation
the allowed-schemes andf safe-hosts checks were being bypassed
when non-ASCII characters were used in a URI

test plan:
 - create an external tool module item
 - attempt to change the URL link to
   javascript:alert(document.domain);//嘊
 - it should be rejected

fixes SEC-2317

Change-Id: Ib2fe75f302af61c596ef2123cc4238975b42698f
Reviewed-on: https://gerrit.instructure.com/189519
Tested-by: Jenkins
Reviewed-by: James Williams <jamesw@instructure.com>
QA-Review: Anju Reddy <areddy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
2019-04-18 19:00:35 +00:00
Rob Orton 96242ba864 fix n+1 in account reports
Change-Id: I7593a6896c23e4825a42b7422e99cb8d481d9503
Reviewed-on: https://gerrit.instructure.com/189769
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins
2019-04-18 02:55:20 +00:00
Cody Cutrer b237a9948d fix encoding issues with bulk inserting of report rows
Change-Id: I33ec2d1f6b7498c27227fec731fbda15c2b09b19
Reviewed-on: https://gerrit.instructure.com/189763
Reviewed-by: Rob Orton <rob@instructure.com>
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
Tested-by: Jenkins
2019-04-18 01:38:45 +00:00
James Williams 4ca2847776 add sis batch setting to disable diffing on high diff row count
test plan:
* use the sis imports API to create a diffed sis batch
* refer to the API docs for 'diff_row_count_threshold'
 to use the setting similarly to 'change_threshold' but
 instead set an explicit row count and confirm that
 diffing does not happen if the number of rows that
 would be run in the diff exceeds the threshold

closes #CORE-2711

Change-Id: Idfc77d0aa64a82cf0665ffb5e3cc31f04d9e60e3
Reviewed-on: https://gerrit.instructure.com/189099
Tested-by: Jenkins
Reviewed-by: Rob Orton <rob@instructure.com>
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-04-16 12:31:50 +00:00
Rob Orton 957a587d1e make helper to load communication_channels
Change-Id: Ia5530e0379f93b7bd81c129fc4fa1796fd21f5b2
Reviewed-on: https://gerrit.instructure.com/189039
Tested-by: Jenkins
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
2019-04-11 19:41:48 +00:00
Rob Orton 4777933f46 make 100 runners for parallel reports
Change-Id: I7323c39638df7e1e5905bcae9e7ed3e4a4df5c49
Reviewed-on: https://gerrit.instructure.com/189021
Tested-by: Jenkins
Reviewed-by: Mark Valentine <mvalentine@instructure.com>
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-04-11 15:50:11 +00:00
Rob Orton 120cb47cce account_report is no longer used for report row
Change-Id: If1ff96244c08e88e61f8ef8c851f3fc2e4904607
Reviewed-on: https://gerrit.instructure.com/188969
Reviewed-by: Mark Valentine <mvalentine@instructure.com>
Tested-by: Jenkins
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-04-10 16:22:38 +00:00
Rob Orton 25aca0dbff spec: raise helpful error when report fails
Change-Id: I3111e149709ee46d6ee7952fcfba06aa553c475c
Reviewed-on: https://gerrit.instructure.com/188947
Tested-by: Jenkins
Reviewed-by: James Williams <jamesw@instructure.com>
QA-Review: James Williams <jamesw@instructure.com>
Product-Review: James Williams <jamesw@instructure.com>
2019-04-10 14:47:50 +00:00
Rob Orton fa72bdf3a7 make helper methods more useful
test plan
 - specs should pass

Change-Id: Ia7ae5f03122760c6cc239094f06fb324f883bf3b
Reviewed-on: https://gerrit.instructure.com/188911
Reviewed-by: Mark Valentine <mvalentine@instructure.com>
Tested-by: Jenkins
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-04-10 03:18:54 +00:00
Rob Orton 09b38f8151 make fewer trips to the db for report runners
we still don’t want to send a giant batch so this
will limit based off the number of ids being sent

refs CORE-2742

test plan
 - specs should pass

Change-Id: Ife00367d818a48a9934b4f224eb865c20292dd31
Reviewed-on: https://gerrit.instructure.com/188807
Tested-by: Jenkins
Reviewed-by: James Williams <jamesw@instructure.com>
QA-Review: James Williams <jamesw@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-04-09 16:57:07 +00:00
Rob Orton 47a4974528 make report runners write to db more efficient
refs CORE-2742

test plan
 - report specs should pass

Change-Id: If11a71145b8ce21be6c91bfcf09f27792a095f68
Reviewed-on: https://gerrit.instructure.com/188692
Tested-by: Jenkins
Reviewed-by: James Williams <jamesw@instructure.com>
QA-Review: James Williams <jamesw@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-04-09 16:56:53 +00:00
Marc Phillips 5fe73fad00 Remove lti11_legacy_user_id
This was removed from the spec.

fixes PLAT-4346

Test Plan:
 - tests pass

Change-Id: I16ff8a72679cfa867e025b2d58d1913796cebfb3
Reviewed-on: https://gerrit.instructure.com/187655
Tested-by: Jenkins
Reviewed-by: Weston Dransfield <wdransfield@instructure.com>
QA-Review: Tucker Mcknight <tmcknight@instructure.com>
Product-Review: Nathan Mills <nathanm@instructure.com>
2019-04-04 15:53:35 +00:00
James Williams 12cc852cd0 add an endpoint to check upcoming partition validity
will return an error if the periodic jobs
haven't been running

closes #CORE-2717

Change-Id: If192f45c0e1f32f53d26287240a717517dcb8440
Reviewed-on: https://gerrit.instructure.com/187809
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-04-03 22:10:47 +00:00
Adrian Packel 35f0cb9e76 Add override score to admin grade reports
Add the override_score field to admin grade reports if the account in
question has the Final Grade Override feature flag either allowed or
enabled.

closes GRADE-2000

Test plan:
- Don't forget to restart delayed_jobs if needed
- Set up an account with FGO set to ALLOW or ON
  - In a course in the account, enable the feature and add some
    override scores
  - Run the admin reports (Grade Export and MGP Grade Export)
  - Both reports should include an override_score column containing
    the relevant values
- Disable FGO on the account
  - Run the reports again
  - The field should not be included in the output

Change-Id: Icd183ae324f52794f1ec80e0e70edb3af95d6a1a
Reviewed-on: https://gerrit.instructure.com/187353
Tested-by: Jenkins
Reviewed-by: Gary Mei <gmei@instructure.com>
Reviewed-by: Keith Garner <kgarner@instructure.com>
QA-Review: James Butters <jbutters@instructure.com>
Product-Review: Keith Garner <kgarner@instructure.com>
2019-03-29 20:52:07 +00:00
Rob Orton 04e7bf8cb8 use inst_statsd
fixes CORE-2538

test plan
 - configure statsd to use data dog
 - it should work

Change-Id: Ie8428e4e99973b35506bd7a8e4d1a18f5a7875a1
Reviewed-on: https://gerrit.instructure.com/182083
Tested-by: Jenkins
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
2019-03-25 17:00:49 +00:00
Rob Orton efe203c1b7 add helper method to for number of items in runner
refs CORE-2598

test plan
 - specs should pass

Change-Id: I3c7490e77e83bcd12b8edda238ede70088b37f84
Reviewed-on: https://gerrit.instructure.com/186554
Reviewed-by: Mark Valentine <mvalentine@instructure.com>
Tested-by: Jenkins
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-03-22 20:24:09 +00:00
Rob Orton e430f35de0 stop logging stats in adheres_to_policy
refs CORE-2538

test plan
 - specs should pass

Change-Id: I09ffd6982be803294b7d70c1e485d999a01352ea
Reviewed-on: https://gerrit.instructure.com/186260
Tested-by: Jenkins
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
2019-03-21 16:29:16 +00:00
Marc Phillips fa3dfcb3d6 Add lti-advantage gem validation
Call the message validations on the lti messages
before we send the launch.

closes PLAT-4117

Test Plan:
 - do a launch, it should still work

Change-Id: I34d20c328173158c76b11aacf7028f7eb152f87b
Reviewed-on: https://gerrit.instructure.com/185216
Tested-by: Jenkins
Reviewed-by: Nathan Mills <nathanm@instructure.com>
QA-Review: Marc Phillips <mphillips@instructure.com>
Product-Review: Marc Phillips <mphillips@instructure.com>
2019-03-15 15:56:34 +00:00
James Williams 2d4b77a3d6 stop and requeue message migration job periodically
break it up into 5 minute chunks

refs #CORE-2558

Change-Id: I00b6d7ffb548a1543e56e6397aeff177a8724f76
Reviewed-on: https://gerrit.instructure.com/185084
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins
2019-03-13 16:49:26 +00:00
Cody Cutrer acd56b976b update mime-types
fixes gh-1390

Change-Id: Idab71c6e9cafd51bf6858f4ba1a07b38f934140e
Reviewed-on: https://gerrit.instructure.com/182668
Tested-by: Jenkins
Reviewed-by: Rob Orton <rob@instructure.com>
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-02-27 17:05:14 +00:00
James Williams 0ee36b92a0 generate locale yaml without line wrapping
Change-Id: Idd1c56b4a9f98e6d90f5d865f192ab9f06b74064
Reviewed-on: https://gerrit.instructure.com/182323
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins
Product-Review: James Williams <jamesw@instructure.com>
2019-02-21 20:16:25 +00:00
Simon Williams 9f96812875 clean up a few more gems/*/Gemfile's
Change-Id: Ida0ea87736d2d22d0019f8cb2a010aeb7b9fafc3
Reviewed-on: https://gerrit.instructure.com/180785
Tested-by: Jenkins
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Simon Williams <simon@instructure.com>
Product-Review: Simon Williams <simon@instructure.com>
2019-02-06 21:54:14 +00:00
Simon Williams 5509b83746 relax live_events' gem development requirements
this allows us to not download the entire aws sdk and old versions of
gems for statsd

Change-Id: Ib8305a008c2270845fd4f7ca5311a86a2e73ce7e
Reviewed-on: https://gerrit.instructure.com/180784
Tested-by: Jenkins
Reviewed-by: Cody Cutrer <cody@instructure.com>
QA-Review: Simon Williams <simon@instructure.com>
Product-Review: Simon Williams <simon@instructure.com>
2019-02-06 21:54:02 +00:00
Simon Williams 63e708f09f spec: a bit of cleanup in gems/ tests
sqlite3 released a new version yesterday, but active record is pinned to
a previous version in a way that just errors. the version pins here can
be reverted once rails releases a compatibility update. see
https://github.com/rails/rails/pull/35154

Change-Id: If9edc76058d96a75b8731422407ecea2afb4ce29
Reviewed-on: https://gerrit.instructure.com/180583
Reviewed-by: James Butters <jbutters@instructure.com>
Tested-by: Jenkins
QA-Review: Simon Williams <simon@instructure.com>
Product-Review: Simon Williams <simon@instructure.com>
2019-02-06 15:19:17 +00:00
James Williams a5a9b26e42 encode i18nliner translation hash as a standard hash
refs #CORE-2352

Change-Id: I06510403b5f7f99de75e28f2655f1fa24ecc0e9d
Reviewed-on: https://gerrit.instructure.com/180026
Reviewed-by: Rob Orton <rob@instructure.com>
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
Tested-by: Jenkins
2019-01-31 17:20:51 +00:00
James Williams f3fdc6da4f add rake task to import new locale from s3
refs #CORE-2350

Change-Id: I2ecc201651e0e00864db9033d858243323a8df2c
Reviewed-on: https://gerrit.instructure.com/179657
Tested-by: Jenkins
Reviewed-by: Rob Orton <rob@instructure.com>
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-01-30 17:32:29 +00:00
James Williams c7609ba733 use psych to export locale yml
closes #CORE-2352

Change-Id: I3f910893e407c9ebcafe0d1bf784170405de489e
Reviewed-on: https://gerrit.instructure.com/179685
Tested-by: Jenkins
Reviewed-by: Rob Orton <rob@instructure.com>
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
2019-01-30 12:42:13 +00:00
Cody Cutrer 0364681e13 fix pruning week-based partitions
Change-Id: I8a8dd135b7da10bd2659251821cb0af0ede5726a
Reviewed-on: https://gerrit.instructure.com/178970
Reviewed-by: James Williams <jamesw@instructure.com>
QA-Review: James Williams <jamesw@instructure.com>
Tested-by: Jenkins
Product-Review: Cody Cutrer <cody@instructure.com>
2019-01-23 16:20:31 +00:00
Cody Cutrer 0f5d186f8e create and drop partitions in a transaction
ensures the database server unshackles itself and hits the master

Change-Id: I7590b230be6a18588547442ca0a0e220b5093873
Reviewed-on: https://gerrit.instructure.com/178971
Tested-by: Jenkins
Reviewed-by: James Williams <jamesw@instructure.com>
QA-Review: James Williams <jamesw@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
2019-01-23 14:57:33 +00:00
Derek Bender 152db32726 add missing test to Utf8Cleaner and cleanup
The added spec covers the real error case that was popping up in
production.

test plan:
- test pass

Change-Id: I20e0915d15bb1f9eba3f9d1bc646df8af1ca8564
Reviewed-on: https://gerrit.instructure.com/177585
Reviewed-by: Adrian Packel <apackel@instructure.com>
Reviewed-by: Keith Garner <kgarner@instructure.com>
Tested-by: Jenkins
QA-Review: Derek Bender <djbender@instructure.com>
Product-Review: Derek Bender <djbender@instructure.com>
2019-01-11 22:10:24 +00:00
James Williams 7c8378782a add a better way to preserve answer ids through copies
migrations from old courses should never use 0
for answer ids and migrations from new ones should
be consistent with their answer ids

closes #QO-458

Change-Id: Ia023b25879530382d5358067cb4ff170c1d41a70
Reviewed-on: https://gerrit.instructure.com/177491
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
Tested-by: Jenkins
QA-Review: James Williams <jamesw@instructure.com>
Product-Review: James Williams <jamesw@instructure.com>
2019-01-11 17:40:44 +00:00
Adrian Packel 6178eacc37 Do not modify encoding of existing string
fixes GRADE-1935

Test plan:
- Specs pass
- In a console, call Utf8Cleaner.strip_invalid_utf8 on a frozen string
  and make sure it doesn't throw an error

Change-Id: I5ede03328bf8dbd58e0350188514427d809c61d1
Reviewed-on: https://gerrit.instructure.com/177551
Reviewed-by: Rob Orton <rob@instructure.com>
QA-Review: Rob Orton <rob@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
Tested-by: Jenkins
2019-01-11 00:19:14 +00:00