learninglocker icon indicating copy to clipboard operation
learninglocker copied to clipboard

RE: #360 IE 9 is not able to getStatements using Tin Can Js (Rustici driver)

Open jeongl opened this issue 12 years ago • 23 comments

Version master at ce4d802a757ef8fc25503e3b5a86268b140b2d55 related to #360

Steps to reproduce the bug Download the golf prototype along with the statement viewer using this single repo - https://github.com/RusticiSoftware/TinCan_Prototypes . Change the config.js.template in the root of the folder to your LRS details, then rename to config.js. Run the golf prototype - Turning the pages will send statements.

Back in the menu, run the statement viewer.

Expected behaviour The statement viewer should return statements

Actual behaviour The statement viewer returns nothing instead with a status 500 when doing GET requests.

Client information - IE9

jeongl avatar Oct 15 '14 07:10 jeongl

I'm a little busy creating phase two of reports at the moment, but this looks like a problem related to #360. I will get round to this once reports are done.

In the meantime could you please modify your comment to follow our issue guidelines. In future you can quickly create issues using our template links which have been provided in the contribution guidelines.

ryasmi avatar Oct 15 '14 08:10 ryasmi

Thanks for updating your comment to comply with our guidelines, it's greatly appreciated! :+1:

ryasmi avatar Oct 16 '14 20:10 ryasmi

No problem Ryan :) I am doing some more testing around this issue. I have tried manual ajax requests as well, but that seems to make no difference.

On Thu, Oct 16, 2014 at 1:59 PM, Ryan Smith [email protected] wrote:

Thanks for updating your comment to comply with our guidelines, it's greatly appreciated! [image: :+1:]

— Reply to this email directly or view it on GitHub https://github.com/LearningLocker/learninglocker/issues/412#issuecomment-59429584 .

jeongl avatar Oct 16 '14 21:10 jeongl

:smile: oh right brilliant, thanks for that. Ok, cheers for the update.

ryasmi avatar Oct 16 '14 21:10 ryasmi

Hey @jeongl, thanks for your patience. I'm currently trying to reproduce your issue. It is producing statements for me, however whilst IE is open with the content any other requests appear to be blocked as if IE is still connected to the LRS. image

ryasmi avatar Oct 23 '14 15:10 ryasmi

This seems to be hanging on one of the PUT requests, but IE sucks so bad that I can't see what the body or headers were on that request. I will continue to look into this tomorrow.

ryasmi avatar Oct 23 '14 16:10 ryasmi

@ryansmith94 It might be helpful to install fiddler on your system? I'll run the prototype again tomm with IE9 and see if I can capture anything while running the golf prototype.

jeongl avatar Oct 24 '14 06:10 jeongl

I think the issue only occurs if you continue from where you left off too.

ryasmi avatar Oct 24 '14 09:10 ryasmi

Hey, I have a solution that will hopefully solve your problem, unfortunately we're handling IE9 posts where method=PUT incorrectly. This is going to be fairly substantial change and right now I have a couple of other more pressing matters to deal with. I will update you as that situation changes with the hope of getting this fixed asap.

ryasmi avatar Oct 24 '14 13:10 ryasmi

Thanks @ryansmith94 I can help test when you might have a solution.

jeongl avatar Oct 24 '14 15:10 jeongl

Very interested to know why this is specific to IE9. or is it 8 too?

garemoko avatar Oct 24 '14 16:10 garemoko

I think it will be the same for versions lower too, when I tested this stuff previously I only tested it with storyline which must use POST not PUT. Hence why I didn't see this issue. On 24 Oct 2014 17:25, "Andrew Downes" [email protected] wrote:

Very interested to know why this is specific to IE9.

— Reply to this email directly or view it on GitHub https://github.com/LearningLocker/learninglocker/issues/412#issuecomment-60411749 .

ryasmi avatar Oct 24 '14 17:10 ryasmi

This may be fixed in the issue/412 branch if you fancy giving it a whirl.

ryasmi avatar Oct 27 '14 14:10 ryasmi

I have just tested the request below in Postman.

POST /data/xAPI/statements?method=PUT HTTP/1.1
Host: localhost:8000
Accept-Language: en-GB
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0) like Gecko
Connection: Keep-Alive
Cache-Control: no-cache

statementId=2d03b85f-0085-4960-b497-e175f6a8ab1a&Content-Type=application/json&Authorization=Basic ZWE3OWRhNTI3ZmU5Y2ZmNDIxMGQzNDU0YmQ1MThiODZiODc1MjljODo4N2QxZjIzM2QyOTNlMjVkYzVjOGU4MDRjYThkYzc5OTNhODA2Mjlh&X-Experience-API-Version=1.0.0&content={"id":"1d03b85f-0085-4960-b497-e175f6a8ab1f","timestamp":"2014-10-24T09:54:55.160Z","actor":{"objectType":"Agent","mbox":"mailto:[email protected]","name":"Ryan Smith"},"verb":{"id":"http://adlnet.gov/expapi/verbs/attempted","display":{"und":"attempted"}},"context":{"registration":"0f0ba460-4493-11e4-916c-0800200c9a66","contextActivities":{"grouping":[{"id":"http://tincanapi.com/GolfExample_TCAPI","objectType":"Activity"}]}},"object":{"id":"http://tincanapi.com/GolfExample_TCAPI","objectType":"Activity","definition":{"type":"http://adlnet.gov/expapi/activities/course","name":{"en-US":"Golf Example - Tin Can Course"},"description":{"en-US":"An overview of how to play the great game of golf."}}}}

ryasmi avatar Oct 27 '14 16:10 ryasmi

I'm testing 9d91337cad243eaf959650b40f45372186139141 right now, but my statements are returning a 500 error. I am getting this error

{"error":true,"message":"Call to undefined function Controllers\\xAPI\\store()","code":500,"trace":[{"function":"handleShutdown","class":"Illuminate\\Exception\\Handler","type":"->","args":[]}]}

I'll keep trying this to make sure it's not something on my end, unless you know of something that might be causing the trouble.

jeongl avatar Oct 27 '14 17:10 jeongl

I just reverted back to f5bd369dc0967e2a4977ea54116db8923071b558 and statements seem to be working. I tested this and the error from the post above with Chrome.

jeongl avatar Oct 27 '14 17:10 jeongl

Yeah sorry about that @jeong, I corrected that mistake.

On 27 October 2014 17:34, jeong [email protected] wrote:

I just reverted back to f5bd369 https://github.com/LearningLocker/learninglocker/commit/f5bd369dc0967e2a4977ea54116db8923071b558 and statements seem to be working. I tested this and the error from the post above with Chrome.

— Reply to this email directly or view it on GitHub https://github.com/LearningLocker/learninglocker/issues/412#issuecomment-60634601 .

ryasmi avatar Oct 27 '14 17:10 ryasmi

I'm still getting an error from PUTs to /data/xAPI/activities/state.

Cannot amend existing application\/octet-stream document with a file

Anyone know if this is something in the spec? @ht2 @davetosh @garemoko @jeongl

ryasmi avatar Oct 27 '14 17:10 ryasmi

I'll have to check but sounds like controls over what documents can be overwritten when using PUT. I'll need to double check the spec though

ht2 avatar Oct 27 '14 18:10 ht2

@ryansmith94 I am not using the state portions of the API, but everything else seems to be working fine in IE9

jeongl avatar Oct 27 '14 20:10 jeongl