How / Why is my p5 / matter.js plinko game crushing my memory?

I have a memory leak. I made a p5 plinko app that hooks into the facebook Graph API so facebook users can comment a number and a chip will drop in the slot of that number. Worked fine when I was developing. But when I ran live on facebook, and captured the window with OBS, the tab crashed after like 30 seconds. Now it crashes with no OBS running, running in an incognito window etc. Chrome 57.0.2987.98. I recorded a memory timeline - p5 and matter.js seem to be the main culprits but I'm not able to dig deeper. I'm working with a 2.5G processor, 16 G ram. OS X 10.12.3. If you wanna give it a shot you can see it in action at https://visuals-2017.herokuapp.com/plinko. It will not display any plinko chips because it only hooks into my personal fb endpoint. source is available at https://github.com/waterjump/visuals/tree/master/app/assets/javascripts

xoxo sean

Tagged:

Answers

  • Answer ✓

    Follow-up: I've learned that its because of a function I used to call a facbeook URL every 5 seconds.

Sign In or Register to comment.