Commit graph

65 commits

Author SHA1 Message Date
Damien Elmes
29a680d8bf fix decimal intervals in revlog as well 2019-02-05 12:30:22 +10:00
Damien Elmes
1675d2f01e fix due column as well in db check 2019-02-04 14:33:53 +10:00
Damien Elmes
41f1ef02de add decimal ivl fix to fixIntegrity() 2019-01-29 08:17:24 +10:00
Damien Elmes
a28973c2aa when rebuilding field cache make sure we don't discard filenames
stripHTMLMedia() already used in notes.py
2018-09-20 15:28:28 +10:00
Damien Elmes
ab57faf58e catch suspended new cards w/ wrong due number
https://anki.tenderapp.com/discussions/ankidesktop/29267-01
2018-08-30 12:43:53 +10:00
Mai Lavelle
128bfcd481 avoid reordering entire deck when importing notes
No need to reorder existing cards, which may have been manually
ordered by the user, when importing notes if we can give cards
a proper due number from the start. Retrieving any sibling's
due number for this is easy as all relevant cards will have
already been queried for when generating the new cards.
2018-07-06 00:49:47 -04:00
Damien Elmes
d3d61ce93f add option to show day learn cards before reviews 2018-01-20 16:07:57 +10:00
Damien Elmes
cf6d85baa4 support sched versions in collection 2018-01-14 16:58:04 +10:00
Damien Elmes
435afed325 fix error when importing 2017-12-12 11:55:27 +10:00
Damien Elmes
81d4b77ee1 more open() and regex strings 2017-12-11 17:25:51 +10:00
Damien Elmes
71101d041a ditch marked tag in favour of card flags
Users can now mark individual cards with one of four different coloured
flags, instead of relying on a tag that applied to the whole note.

- replaced marking functionality in reviewer and browser with new
flag options
- added flag:x search
- marked and leech tags now show in normal tag list in filter screen,
instead of being treated specially
- the other clients will need updating to set and shown the flags, but
flags set in the beta should be preserved by the other clients
2017-08-12 16:08:10 +10:00
Damien Elmes
82aeb57318 Revert "experiment with displaying FrontSide under answer"
This reverts commit a1b0ddb00c.
2017-08-10 15:04:24 +10:00
Damien Elmes
a1b0ddb00c experiment with displaying FrontSide under answer
- avoids having to move eyes to answer section
- the fade out/fade in step feels more natural when the
question section moves

feedback welcome
2017-08-07 18:38:35 +10:00
Damien Elmes
0543a4533b add devMode flag to utils
also remove the extra toolbar call in loadProfile(), as we require a
restart to update the translations anyway
2017-08-01 14:28:13 +10:00
Damien Elmes
1dd17e9f3a when reviews have incorrect due date, make them due today
https://anki.tenderapp.com/discussions/ankidesktop/19394-strange-behavior-with-year-long-intervals#comment_42510830
2017-05-09 12:27:23 +10:00
Damien Elmes
4430785122 fix error when closing collection on python 3.6 2017-02-08 19:41:44 +10:00
Illia Volochii
13b7e01044 Stop inheriting from object
It is not needed in Python 3.
2017-02-07 00:21:33 +02:00
Damien Elmes
e6adc3c195 fixes for sqlite on python 3.6
we need to switch to autocommit mode before executing vacuums &
certain pragmas

also removed the pysqlite version workaround; we just use the
python-provided versions in all cases now as it is new enough
2017-01-13 17:00:03 +10:00
Damien Elmes
a05ebdbefb do GC on autosave
- ensures we're not called as part of the db progress callback
- minimises the chance of data loss if a gc causes a crash
2017-01-13 16:20:39 +10:00
Damien Elmes
4fbe091c3b don't reload data on close 2016-12-24 15:33:46 +10:00
Damien Elmes
ddbf634dd5 longer ivl limit in db check
https://anki.tenderapp.com/discussions/ankidesktop/19394-strange-behavior-with-year-long-intervals
2016-08-24 14:38:04 +10:00
Damien Elmes
f8e300ab1d use utf8 for collection.log 2016-07-07 12:03:02 +10:00
Damien Elmes
15b349e3a8 start port to python 3
unit tests pass and main screens of GUI load
2016-05-12 14:45:35 +10:00
rizzomichaelg
610ca050eb Adding new cloze while in filtered deck
When adding a new cloze tag while a card is in a filtered deck, anki currently adds the new card to the Default deck.  

My proposed fix checks if the card has the odid field set and then sets the did to use when generating the new cards as the odid.
2016-04-09 08:46:54 -05:00
Dave Shifflett
2e38174921 Cast template deck ID before checking the decks
The keys of `self.decks.decks` are unicode keys whereas `template['did']`
is an integer, so `template['did'] in self.decks.decks` always fails.
2016-02-29 21:03:48 -06:00
Timothy Rae
38b36323da Don't use default deck when deck override set to invalid deck
When the override deck is not valid, the more intuitive behavior for users is to not override. Advanced users that really want to use this feature will immediately open the deck override settings and see that it's referencing an invalid deck. Advanced users and developers have all been stumped by the old behavior, it's simply not intuitive.
2016-02-16 12:26:52 +09:00
Damien Elmes
6e7e08ebd0 be explicit about modSchema()'s check flag
- remove gui code that adds exceptions for syncing
- use check=False for all syncing and upgrade code
2014-11-03 16:28:12 +09:00
Soren I. Bjornstad
a430803774 Merge branch 'master' of https://github.com/dae/anki 2014-09-27 10:18:10 -05:00
Damien Elmes
ba7abb53e2 make sure we save note type after fixing ad bug 2014-09-27 10:32:21 +09:00
Soren I. Bjornstad
dd0e6f2a65 add {{Subdeck}} special field
If the deck is a several levels into a tree, it can be needlessly
verbose to list them.
2014-09-23 10:03:19 -05:00
Houssam Salem
7b62094ea0 Add odid fix to db check (#1035) 2014-05-26 15:11:47 +10:00
Damien Elmes
d56cf3c6b0 add fix for AD issue 2014-04-01 13:13:59 +09:00
Damien Elmes
980c9d7305 Merge branch 'master' of https://github.com/hssm/anki 2014-02-21 13:38:02 +09:00
Houssam Salem
8b443e80ef Remove leech tag on undo if it was added during that review (#973). 2014-02-20 16:51:08 +11:00
Julien Baley
777a3b8ec3 Fixes behaviour for {{type:cloze:Field}} 2014-02-19 10:09:48 +00:00
Julien Baley
7e3597fb8e Adding support for chained modifiers. One can now write e.g. {{cloze:text:Field}} or {{text:cloze:Field}}, it's order independent. 2014-02-18 17:24:28 +00:00
Damien Elmes
44b83d9bd8 switch over to per-day sibling burying 2014-01-14 14:18:42 +09:00
Damien Elmes
636d70ab16 make sure we reopen log after export 2013-12-02 23:57:56 +09:00
Damien Elmes
742a520954 make sure to close debug log when closing collection 2013-12-01 01:44:47 +09:00
Damien Elmes
ae8074ec01 make sure we reset odue when rescheduling as new
if we fail to do this for a relearning card, it sticks around
until it causes problems later
2013-11-17 16:03:58 +09:00
Damien Elmes
75f87201a2 rotate log file when it hits 10MB 2013-11-13 17:00:20 +09:00
Damien Elmes
c3300f733a make sure we don't 'fix' req for cloze type 2013-11-13 16:49:49 +09:00
Damien Elmes
ef9157a8ee don't open log for export or upgrade, only regular+sync 2013-11-13 16:48:22 +09:00
Damien Elmes
d7e452de1f fix note types with missing reqs 2013-11-13 08:33:54 +09:00
Damien Elmes
5dfe95aa67 move debug logging into libanki
we want to be able to log the initial automatic sync, which
happens before the debug logging was set up in ankiqt

also skip the flush, as it should eventually get written
2013-11-04 23:04:27 +09:00
Damien Elmes
3348b091d0 tweak logging
- log only sched getCard(), not all getCard calls
- don't log sched.today unless it's changed
2013-10-30 22:42:32 +09:00
Damien Elmes
0fbc94c186 more logging tweaks
- disable in browser, note.cards()
- in getCard() we want the calling frame, not us
- log current day
- show card/note id in card info stat
2013-10-18 14:20:20 +09:00
Damien Elmes
b99533a5ad add logging to some scheduling and syncing code 2013-10-18 11:52:21 +09:00
Damien Elmes
e9ab9128c8 we can remove graves when uploading and save space 2013-10-11 12:21:59 +09:00
Damien Elmes
0bef1d8530 unbury on open/close and make sure we set usn when unburying 2013-09-04 04:38:00 +09:00