ewanbrinkman / sfu-course-api-wrapper

An asynchronous TypeScript wrapper for SFU's course API.
MIT License
1 stars 0 forks source link

`BluebirdPromise.map` with `concurrency` > 1 can cause duplicates in result #25

Closed ewanbrinkman closed 5 months ago

ewanbrinkman commented 5 months ago

Multiple copies of a course (usually 2 copies) will be in the result. To make up for the extra duplicate, it looks like some other course doesn't make it into the result.

Setting concurrency to 1 avoids this issue.

ewanbrinkman commented 5 months ago

To fix this issue, could try implementing my own queue system instead of using BluebirdPromise.map.