NUDelta / pair-research-meteor

A Meteor Implementation of the Pair Research Tool
3 stars 2 forks source link

Make pairs yields "500 server error" AJAX responses #23

Closed JoeGermuska closed 7 years ago

JoeGermuska commented 7 years ago

We attempted a peer research session yesterday with about 30 people. When the time came to click "make pairs," we got no visible response. When people looked in the inspector console, they saw 500 server error messages.

Shortly after we tried with a smaller pool (3 people) and had no problem at all.

bomanimc commented 7 years ago

Adding some information: We were able to identify that the issue is caused because a null weight value in the edges array is passed into the matching algorithm (pair_research.py). Here's the edges array that failed in this case:

'[[0,7,34],[0,8,62],[0,26,9],[1,3,76],[1,4,52],[1,5,79],[1,6,95],[1,7,94],[1,8,74],[1,10,59],[1,12,52],[1,16,83],[1,18,92],[1,19,48],[1,21,49],[1,23,33],[2,5,34],[2,10,11],[2,16,47],[2,22,3],[2,23,38],[2,26,33],[3,5,63],[3,7,73],[3,11,33],[3,13,36],[3,16,69],[3,18,82],[3,19,78],[3,22,69],[3,24,87],[3,26,38],[4,6,85],[4,8,42],[4,11,45],[4,12,48],[4,13,48],[4,14,53],[4,16,55],[4,18,63],[4,19,55],[4,21,88],[4,22,51],[4,26,68],[5,6,50],[5,8,24],[5,15,79],[5,16,55],[5,18,52],[5,19,57],[5,20,30],[5,21,101],[5,22,48],[5,25,94],[5,26,67],[5,28,3],[5,29,60],[6,7,73],[6,11,67],[6,12,85],[6,13,60],[6,15,47],[6,16,75],[6,17,62],[6,19,44],[6,21,67],[6,22,64],[6,26,68],[6,29,48],[7,8,54],[7,11,65],[7,12,56],[7,13,63],[7,14,59],[7,16,58],[7,18,67],[7,19,68],[7,21,94],[7,22,80],[7,25,42],[7,26,55],[8,11,67],[8,12,81],[8,13,85],[8,14,65],[8,16,72],[8,21,63],[8,22,79],[8,26,45],[9,12,11],[9,28,2],[11,12,119],[11,13,null],[11,19,19],[11,21,43],[11,22,12],[11,24,67],[12,13,104],[12,19,45],[12,20,4],[12,21,35],[12,22,31],[12,25,69],[12,26,82],[12,28,40],[13,19,28],[13,21,34],[13,22,17],[13,24,58],[14,19,29],[14,20,20],[14,21,66],[14,22,82],[14,25,40],[14,28,67],[15,16,53],[15,19,31],[16,17,53],[16,19,36],[16,20,57],[16,21,33],[16,22,69],[16,24,83],[16,26,3],[16,29,25],[17,24,86],[17,28,65],[17,29,39],[18,19,58],[18,22,62],[19,20,69],[19,21,19],[19,22,59],[19,29,2],[20,26,32],[20,28,61],[21,22,85],[22,26,90],[22,27,28],[23,28,39],[25,26,29],[25,27,52],[26,27,110],[26,28,34]]'

Not sure yet why this happened, but a simple (probably sub-optimal) fix could just be to replace nulls in this array with 0.

bomanimc commented 7 years ago

Deployed a change that we believe should correct this issue for now. We can reopen again if this is still an issue!