Damien Elmes 2018-06-01 12:24:11 +10:00
parent 99c50f1a93
commit 01c58cfd85
2 changed files with 3 additions and 3 deletions

View File

@ -896,7 +896,7 @@ select id from cards where did in %s and queue = 2 and due <= ? limit ?)"""
delay = self._daysLate(card) delay = self._daysLate(card)
conf = self._revConf(card) conf = self._revConf(card)
fct = card.factor / 1000 fct = card.factor / 1000
ivl2 = self._constrainedIvl((card.ivl + delay // 4) * 1.2, conf, card.ivl, fuzz) ivl2 = self._constrainedIvl(card.ivl * 1.2, conf, card.ivl, fuzz)
if ease == 2: if ease == 2:
return ivl2 return ivl2

View File

@ -325,8 +325,8 @@ def test_reviews():
d.reset() d.reset()
d.sched.answerCard(c, 2) d.sched.answerCard(c, 2)
assert c.queue == 2 assert c.queue == 2
# the new interval should be (100 + 8/4) * 1.2 = 122 # the new interval should be (100) * 1.2 = 120
assert checkRevIvl(d, c, 122) assert checkRevIvl(d, c, 120)
assert c.due == d.sched.today + c.ivl assert c.due == d.sched.today + c.ivl
# factor should have been decremented # factor should have been decremented
assert c.factor == 2350 assert c.factor == 2350