Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fill in the blanks activity memory leak, activity uses 2 GB of memory in moodle but works fine on wordpress #259

Closed
mgancarzdsi opened this issue Mar 13, 2019 · 2 comments

Comments

@mgancarzdsi
Copy link

Strange scenario here, but I think there is some slight implementation differences between the way the Fill in the blanks activity works on Moodle versus Wordpress that cause a memory leak on the client browser side.

This activity: https://h5p.org/node/456374 seems to work fine on h5p.org and our own Wordpress site. However, when we import the .h5p file it into our Moodle, clicking "Check" causes Google Chrome to start using memory until it reaches about 2 GB, at which point the tab crashes. In Internet Explorer it takes a while but works, though it uses up roughly 1.7 GB of memory while the activity grading is taking place.

Deleting one of the questions does reduce the memory usage and allows the "Check" to complete without Google Chrome crashing.

We created the activity in our Moodle, on Moodle version 3.5.3 and H5P plugin version 1.14. I also updated our H5P plugin to latest 1.17.1 and the same behaviour still happens.

@thomasmars
Copy link
Member

Hi, this is an issue with the implementation of Fill in the Blanks' getXAPIData() function/contract and the xAPI specification. When there are many alternatives for each blank generating the xAPI statement becomes exponentially big. This manifests in Moodle since it is the only platform that calls the getXAPIData() contract to generate reports. Please move this issue to the Blanks repository, as that is the library that has to change its' implementation of getXAPIData() in order to not crash. Thanks.

@mgancarzdsi
Copy link
Author

Thank you for the quick reply Thomas. Moved it over

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants