zeeguu / web

Frontend for the zeeguu web application.
https://www.zeeguu.org
3 stars 5 forks source link

Exercises Crashes due to not enough Bookmarks #278

Closed tfnribeiro closed 6 months ago

tfnribeiro commented 6 months ago

When changing the number of exercises, I noticed that we get Unassigned bookmarks.

Turns out this is due to the fact that we don't take into consideration the number of bookmarks needed to complete an exercise when assigning bookmarks. This variable is decremented once, despite using 3 bookmarks for example. This results in the final exercises not having available bookmarks and being assigned Null.

image

Seems that in the past NUMBER_OF_BOOKMARKS_TO_PRACTICE would be +1 the total number of possible exercise bookmarks so this wasn't seen. However, this variable might change and the exercises could break due to this.