Go to file
Adrian Packel f7e168c77b Submit only one comment at a time in SG
Do not attempt to submit comments in SpeedGrader if a submission request
is already in progress. Although we already disable the "Submit" button
while waiting for a response, navigating between students would still
attempt to record the current comment text as a draft (even if the user
had already explicitly saved it) without checking whether a request was
in progress.

flag=none
fixes TALLY-620

Test plan:

- Have a course with an assignment and some students
- Open SpeedGrader for the assignment

- Ensure the server will take a while to process comment requests
  - To do this, you can make a change on the server to force a reload
    (e.g., add a line to update_submission in gradebooks_controller),
    or get yourself a terrible internet connection if you're not testing
    locally.

- Ensure non-draft comments aren't wrongly saved as drafts:
  - Type some text in the comment box for a student
  - Click "Submit"
  - Immediately start hitting the "j" and/or "k" keys with great vigor
  - This should *not* cause a zillion draft comments to be saved
  - Eventually the actual submission request should finish, and should
    add a non-draft comment for the intended student (and only that
    student)
- Ensure draft comments only get one copy saved:
  - Slow down your server again, as above
  - Type some comment text, but do not submit it
  - Using the arrow buttons at the top, furiously move between students
  - This should *not* cause zillions of draft comments to be saved
  - Eventually, the actual draft comment should be saved for the
    intended student (and only that student)
- Ensure the more civilized behavior below works as expected:
  - Submitting a comment and calmly waiting for the submission to go
    through
  - Typing some comment text, switching students, and waiting for the
    draft comment to be saved without making a ruckus
  - Typing some comment text, closing the page, and then re-opening the
    page with no hullabaloo (the text should have been saved as a draft)

Change-Id: I57e0781333c763ba22842749f0130fe6c21eb319
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/237373
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Product-Review: Spencer Olson <solson@instructure.com>
Reviewed-by: Gary Mei <gmei@instructure.com>
Reviewed-by: Jeremy Neander <jneander@instructure.com>
QA-Review: Robin Kuss <rkuss@instructure.com>
2020-05-22 15:00:11 +00:00
.github update PR auto assignments 2019-10-24 21:19:48 +00:00
Gemfile.d bump rails 2020-05-19 20:06:52 +00:00
app Add FF for Hide Course Sections from Students 2020-05-22 14:06:32 +00:00
bin spec: revert pact scripts in bin/ to use web 2020-05-15 19:47:55 +00:00
build Upload rspec and selenium events to splunk 2020-05-18 21:06:01 +00:00
client_apps Add user_ids to quiz statistics endpoint 2019-12-04 19:24:27 +00:00
config Add FF for Hide Course Sections from Students 2020-05-22 14:06:32 +00:00
db/migrate make submission course_id not null 2020-05-21 16:50:37 +00:00
doc Remove broken/obsolete content from styleguide 2020-05-15 17:47:09 +00:00
docker-compose spec: upgrade the selenium-chrome docker version 2020-05-14 02:32:38 +00:00
frontend_build remove unused selinimum gem 2020-04-23 17:25:57 +00:00
gems spec: remove explicit jest guidance for now 2020-05-20 19:21:42 +00:00
hooks fix pre-commit hook with unfixable eslint error 2018-11-27 23:28:12 +00:00
jest Make type filter searchable on courses main list 2020-05-19 01:24:11 +00:00
lib Add setting to hide students from other sections 2020-05-21 20:01:41 +00:00
packages [i18n] Update package translations 2020-05-22 04:46:55 +00:00
pact Include context_name in planner item response 2018-08-29 22:20:52 +00:00
public Submit only one comment at a time in SG 2020-05-22 15:00:11 +00:00
script remove skipping linters if whitelisted engineer 2020-05-08 15:17:49 +00:00
spec Submit only one comment at a time in SG 2020-05-22 15:00:11 +00:00
.bowerrc introduced bower to manage js dependencies 2013-12-13 17:45:57 +00:00
.codeclimate.yml disable ESLint in code climate 2017-02-14 17:47:39 +00:00
.dive-ci Spec: Add dive build 2020-03-26 14:52:06 +00:00
.dockerignore use parallel_tests for more parallelization 2020-03-30 21:38:47 +00:00
.editorconfig Add EditorConfig configuration file to help maintain code style 2016-11-15 20:08:55 +00:00
.eslintignore Run prettier on packages/ 2019-10-11 19:29:16 +00:00
.eslintrc.js Update eslint rules to allow optional chaining 2020-05-07 12:38:29 +00:00
.gitignore use parallel_tests for more parallelization 2020-03-30 21:38:47 +00:00
.gitmessage prepend some blank lines to .gitmessage 2019-08-09 16:12:53 +00:00
.i18nignore bump rails 3 to github branch for ruby 2.2 compatibility 2015-02-18 22:55:20 +00:00
.i18nrc upgrade to node 6 2016-08-09 23:37:07 +00:00
.lintstagedrc.js Remove prettier whitelist 2019-10-11 19:29:31 +00:00
.npmrc fix brand config previewing and skipping 2015-10-27 16:16:15 +00:00
.nvmrc require node 10.16 for brotli support 2020-04-03 19:48:37 +00:00
.prettierrc Add .prettierrc so it matches our existing code 2017-11-03 16:21:50 +00:00
.rubocop.yml Remove duplicated config in .rubocop.yml 2020-01-30 22:41:56 +00:00
.stylelintrc Lint for css that will break RTL 2018-10-17 20:21:25 +00:00
.travis.yml more travis builds 2014-02-10 16:23:19 +00:00
CONTRIBUTING.md Add CLA FAQ from legal 2018-01-22 16:41:44 -05:00
COPYRIGHT Initial commit. 2011-01-31 18:57:29 -07:00
Dockerfile remove unused selinimum gem 2020-04-23 17:25:57 +00:00
Dockerfile-production Default Dockerfiles to 2.4-xenial 2020-03-19 21:51:38 +00:00
Dockerfile.githook Add precommit hook for auto fixing files 2018-11-27 21:07:31 +00:00
Dockerfile.package-translations Create shared translation infrastructure for packages 2019-11-06 22:42:03 +00:00
Gemfile drop rails 5.1 2019-08-01 14:09:31 +00:00
Jenkinsfile Extract splunk events into common file 2020-05-15 20:47:10 +00:00
Jenkinsfile.contract-tests spec: revert pact scripts in bin/ to use web 2020-05-15 19:47:55 +00:00
Jenkinsfile.dive Add timestamps to all builds 2020-05-08 22:20:37 +00:00
Jenkinsfile.js spec: more parallel of docker, better even 2020-05-11 15:07:18 +00:00
Jenkinsfile.main-for-coverage Add timestamps to all builds 2020-05-08 22:20:37 +00:00
Jenkinsfile.master-bouncer-check-all Add timestamps to all builds 2020-05-08 22:20:37 +00:00
Jenkinsfile.package-translations Add timestamps to all builds 2020-05-08 22:20:37 +00:00
Jenkinsfile.selenium.flakey_spec_catcher spec: more parallel of docker, better even 2020-05-11 15:07:18 +00:00
Jenkinsfile.selenium.performance.chrome spec: more parallel of docker, better even 2020-05-11 15:07:18 +00:00
Jenkinsfile.test-subbuild Add timestamps to all builds 2020-05-08 22:20:37 +00:00
Jenkinsfile.vendored-gems Add timestamps to all builds 2020-05-08 22:20:37 +00:00
Jenkinsfile.xbrowser spec: more parallel of docker, better even 2020-05-11 15:07:18 +00:00
LICENSE Initial commit. 2011-01-31 18:57:29 -07:00
README.md Update README.md since Canvas is still modern 2016-12-15 03:18:28 +00:00
Rakefile use parallel_tests for more parallelization 2020-03-30 21:38:47 +00:00
babel.config.js Fix the build 2019-09-17 21:26:07 +00:00
bower.json Move k5uplodaer to /packages 2019-05-10 18:30:51 +00:00
code_of_conduct.md contributor code of conduct 2014-12-23 18:13:59 +00:00
config.ru remove extra logging to debug Passenger connection orphan issue 2017-07-14 16:27:03 +00:00
docker-compose.jenkins.yml update rce-api version on jenkins second attempt 2019-07-19 20:24:19 +00:00
docker-compose.new-jenkins-flakey-spec-catcher.yml spec: more parallel of docker, better even 2020-05-11 15:07:18 +00:00
docker-compose.new-jenkins-karma.yml spec: more parallel of docker, better even 2020-05-11 15:07:18 +00:00
docker-compose.new-jenkins-package-translations.yml Create shared translation infrastructure for packages 2019-11-06 22:42:03 +00:00
docker-compose.new-jenkins-selenium.yml spec: upgrade the selenium-chrome docker version 2020-05-14 02:32:38 +00:00
docker-compose.new-jenkins.canvas.yml spec: more parallel of docker, better even 2020-05-11 15:07:18 +00:00
docker-compose.new-jenkins.consumer.yml add smoke test for using canvas-lms image as a consumer 2020-05-13 16:54:14 +00:00
docker-compose.new-jenkins.multiple-processes.yml spec: more parallel of docker, better even 2020-05-11 15:07:18 +00:00
docker-compose.new-jenkins.vendored-gems.yml spec: more parallel of docker, better even 2020-05-11 15:07:18 +00:00
docker-compose.new-jenkins.yml spec: more parallel of docker, better even 2020-05-11 15:07:18 +00:00
docker-compose.spring.yml remove unused selinimum gem 2020-04-23 17:25:57 +00:00
docker-compose.yml Remove DATABASE_URL from docker dev envs 2020-04-29 19:09:35 +00:00
gulpfile.js fix polyfill for old browsers 2019-09-09 20:00:17 +00:00
issue_template.md Make issue template disclaimer a comment 2018-05-01 15:00:27 +00:00
jest.config.js add conference ui to calendar details page 2020-04-30 18:06:11 +00:00
karma.conf.js Allow forcing a failure in each JS stage 2020-01-20 21:18:25 +00:00
package.json Update eslint rules to allow optional chaining 2020-05-07 12:38:29 +00:00
parallel_runtime_rspec.log spec: update the parallel log 2020-05-05 14:59:16 +00:00
stats-prod.json spec: create network fake for testing ajax 2020-04-28 14:47:35 +00:00
webpack.config.js Opt our js build tooling dirs into prettier 2018-11-07 22:46:16 +00:00
webpack.test.config.js upgrade webpack to v4 2019-05-16 15:59:04 +00:00
yarn.lock Update eslint rules to allow optional chaining 2020-05-07 12:38:29 +00:00

README.md

Canvas LMS

Canvas is a modern, open-source LMS developed and maintained by Instructure Inc. It is released under the AGPLv3 license for use by anyone interested in learning more about or using learning management systems.

Please see our main wiki page for more information

Installation

Detailed instructions for installation and configuration of Canvas are provided on our wiki.