Canvas - Failed sending grade to platform! HTTPError: Internal Server Error
See original GitHub issueDescribe the bug
I’m running the Example Ltijs Server, when I click on “submit grade” I’m getting Failed sending grade to platform! HTTPError: Internal Server Error
Expected behavior Post grades to the canvas
Provider logs provider:main Attempting to connect to database +0ms provider:database Database connected +0ms provider:database Database connection open +3ms provider:main Ltijs started listening on port: 3000 +39ms
| | |__ | | | |/ |
| | | | | | | | (
| | | | | | _ | |_
| |____| | | | | || |) |
||| |()___/|/
LTI Provider is listening on port 3000!
LTI provider config:
App Route: / Initiate Login Route: /login Keyset Route: /keys Session Timeout Route: /sessiontimeout Invalid Token Route: /invalidtoken
Starting in Dev Mode, state validation and session cookies will not be required. THIS SHOULD NOT BE USED IN A PRODUCTION ENVIRONMENT! provider:main Platform already registered +28ms provider:main Receiving request at path: /grade +7m provider:main Path does not match reserved endpoints +0ms provider:main Cookies received: +0ms provider:main [Object: null prototype] { provider:main ‘ltiaHR0cHM6Ly9jYW52YXMuaW5zdHJ1Y3R1cmUuY29tMTYxMDgwMDAwMDAwMDAwMTA3MTUwOjY2Y2FjNTJkODY4N2UyZTBmYjJmOTM3ODc0YzM1ZjdlZTE5ZGU4YWU%3D’: ‘a711bf8e-7a3a-464b-952d-5cd48d142cfc’ provider:main } +0ms provider:main LTIK found +1ms provider:main LTIK successfully verified +2ms provider:main Attempting to retrieve matching session cookie +0ms provider:main Dev Mode enabled: Missing session cookies will be ignored +0ms provider:auth Valid session found +0ms provider:main Passing request to next handler +16ms provider:gradeService Target platform: https://canvas.instructure.com +0ms provider:gradeService Attempting to retrieve platform access_token for [https://canvas.instructure.com] +3ms provider:platform Valid access_token for https://canvas.instructure.com not found +0ms provider:platform Attempting to generate new access_token for https://canvas.instructure.com +0ms provider:platform With scopes: https://purl.imsglobal.org/spec/lti-ags/scope/lineitem https://purl.imsglobal.org/spec/lti-ags/scope/score +0ms provider:auth Awaiting return from the platform +0ms Response code 500 (Internal Server Error)
Screenshots
Ltijs version
- Version [5.3.3]
NodeJS version
- Version [12]
Platform used
- [Canvas]
Additional context await lti.registerPlatform({ url: ‘https://canvas.instructure.com’, name: ‘Canvas sandbox’, clientId: ‘XXXXXXXXX’, authenticationEndpoint: ‘https://kaplanlabs.instructure.com/api/lti/authorize_redirect’, accesstokenEndpoint: ‘https://kaplanlabs.instructure.com/login/oauth2/token’, authConfig: { method: ‘JWK_SET’, key: ‘https://kaplanlabs.instructure.com/api/lti/security/jwks’ } })
Issue Analytics
- State:
- Created 3 years ago
- Comments:8 (4 by maintainers)
Thanks a lot for the quick response! really appreciate it.
@Cvmcosta I get the same error. My error Message is Failed sending grade to platform! HTTPError: 500.
You mean that the canvas instance must be hostet on a server so that it is accessable from the internet, and the LTI App should also be accessable from the internet.
So my canvas instance ist hosted and accessible from the internet and my canvas LTI App is running over nkrog-tunnle, so it is also accessible. But I am getting the error message. When I use only localhost as you descibed before it is also not working.