hypothesis / hypothesis/lms

Installation of Canvas app gives errors with an URL and Canvas Files assignment, and not with a Google Picker assignment

Open
#1,449 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
53
Forks
16
Avg merge
14d 5h
Merged PRs (30d)
14

Description

https://hypothesis.zendesk.com/agent/tickets/8297

I suggested I write this up before the last email in the thread, which made this sound like the person installing the Canvas app was maybe not following our directions, but rather powering through on their own. Because I'm still not 100% sure if this is the case, and because the email thread contains error messages I can't understand, I'm documenting it here.

The issue:
Someone installing our Canvas app in both a test server and a prod server is having intermittent trouble getting URL assignments and Canvas File assignments to work, but reports that Google picker assignments work.

The prod server is https://canvas.glicc.jp/ and the test server is https://canvas.zero2one.co.jp/. It appears as though Key/Secrets with Canvas Dev credentials have been made for both.

The user started by saying they were getting the following error when creating a Canvas Files assignment:
Screen Shot 2020-02-08 at 2 18 04 PM

They uninstalled and re-installed Canvas, making sure they had added Dev credentials.

Then, if I understand correctly, one instance of Cavnas was giving them errors, and the other wasn't. Here's the error codes I can't understand:

> Following is failed case …
```
#######################################################
https://canvas.glicc.jp/api/v1/courses/64/modules/264/items
=>
while(1);[{"id":826,"title":"Hypothesis","position":1,"indent":0,"type":"ExternalTool","module_id":264,"html_url":"https://canvas.glicc.jp/courses/64/modules/items/826","content_id":117,"url":"https://canvas.glicc.jp/api/v1/courses/64/external_tools/sessionless_launch?launch_type=module_item&module_item_id=826","external_url":"https://lms.hypothes.is/lti_launches?url=https%3A%2F%2Fwww.yahoo.co.jp%2F","new_tab":false,"published":false}]
https://canvas.glicc.jp/api/v1/courses/64/external_tools/sessionless_launch?launch_type=module_item&module_item_id=826
=>
while(1);{"id":117,"name":"Hypothesis","url":"https://canvas.glicc.jp/courses/64/external_tools/sessionless_launch?verifier=53c0adaedb326975bd4e3b77207234bf30a96cd4dec2d3aeec63aac491fb3801fb28105e97b6a8f8d113831b60f3c1d717340ccba7f680befbbc71a300e50e2f"}
https://canvas.glicc.jp/courses/64/external_tools/sessionless_launch?verifier=53c0adaedb326975bd4e3b77207234bf30a96cd4dec2d3aeec63aac491fb3801fb28105e97b6a8f8d113831b60f3c1d717340ccba7f680befbbc71a300e50e2f
=>
https://lms.hypothes.is/lti_launches?url=https%3A%2F%2Fwww.yahoo.co.jp%2F
=>
Hypothesis received an invalid request. There were problems with these request parameters:
url:
Missing data for required field.
###############################################################################################
```

> And following is successful case ….
```
######################################
https://canvas.glicc.jp//api/v1/courses/20/module_item_sequence?asset_type=ModuleItem&asset_id=824&frame_external_urls=true
=>
while(1);{"items":[{"current":{"id":824,"title":"Hypothesis","position":1,"indent":0,"type":"ExternalTool","module_id":268,"html_url":"https://canvas.glicc.jp/courses/20/modules/items/824","content_id":115,"url":"https://canvas.glicc.jp/api/v1/courses/20/external_tools/sessionless_launch?launch_type=module_item&module_item_id=824","external_url":"https://lms.hypothes.is/lti_launches?url=https%3A%2F%2Fdrive.google.com%2Fuc%3Fid%3D11czuroRO7siT0PlnngQ6zJHt12_7J1rJ%26export%3Ddownload","new_tab":false,"published":false},"prev":null,"next":null}],"modules":[{"id":268,"name":"First Stage","position":1,"unlock_at":null,"require_sequential_progress":false,"publish_final_grade":false,"prerequisite_module_ids":[],"published":false,"items_count":1,"items_url":"https://canvas.glicc.jp/api/v1/courses/20/modules/268/items"}]}
https://canvas.glicc.jp/api/v1/courses/20/external_tools/sessionless_launch?launch_type=module_item&module_item_id=824
=>
while(1);{"id":115,"name":"Hypothesis","url":"https://canvas.glicc.jp/courses/20/external_tools/sessionless_launch?verifier=b68750fb757e2555ff812a3be04c0560098ce15f1d686ae49dbcb386a96ae044b32b2d481c3f59d30479284ed5f35de6c1c58bc07359e6249b245050145b86bb"}
https://canvas.glicc.jp/courses/20/external_tools/sessionless_launch?verifier=b68750fb757e2555ff812a3be04c0560098ce15f1d686ae49dbcb386a96ae044b32b2d481c3f59d30479284ed5f35de6c1c58bc07359e6249b245050145b86bb
=>
https://lms.hypothes.is/lti_launches?url=https%3A%2F%2Fdrive.google.com%2Fuc%3Fid%3D11czuroRO7siT0PlnngQ6zJHt12_7J1rJ%26export%3Ddownload
OK
##############################################################
```

> Both case, send URL as parameter … I do not see any issue from above …. I am not sure why there is error …

Finally, he said:

> I finally make it happen except CANVAS file which is still auth error.
> I disable two feature of account and make it work.
> **Don't Move LTI Query Params to POST Body**
> **Encrypted Sourcedids for Basic Outcomes**

This is when I suspected he might be installing our app without following our instructions. However, being unable to read the error above, I'm not sure if there's something here I can heklp with or not.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.