Commit graph

16 commits

Author SHA1 Message Date
Damien Elmes
d8d7e78b6b remove typings from some other files
not used frequently enough to deal with the mypy errors they're causing
at the moment
2019-12-20 16:33:49 +10:00
Damien Elmes
55795822b5 importing 2019-12-20 11:41:24 +10:00
Damien Elmes
6ecfff56c5 add pytype inferred types to anki/
I've corrected some obvious issues, and we can fix others over time.
Mypy tests are currently broken, as adding the type hints has increased
mypy's testing surface.
2019-12-20 11:07:08 +10:00
Damien Elmes
c9820fae99 ignore missing props in the supermemo importer 2019-12-16 17:50:43 +10:00
Damien Elmes
b4b8717a20 set instance vars in __init__() 2019-12-16 17:49:32 +10:00
Damien Elmes
6e077ab414 use raw strings for regexs 2019-03-04 17:03:43 +10:00
Damien Elmes
4037a034aa fix inconsistent indentation 2019-03-04 16:54:22 +10:00
Damien Elmes
3721cc4604 silence some spurious errors and remove some unused code 2019-03-04 11:22:40 +10:00
Rémy Léone
8f1ad57931 Comparison with None shouldn't use equality
That type of comparisons should always be done with 'is' or 'is not',
never the equality operators.
2017-09-10 15:30:22 +02: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
Jussi Maatta
656698da83 Add A-factor to E-factor conversion to SuperMemo import.
The SuperMemo XML importer assumed that the A-factors used by
SuperMemo map 1-1 with E-factors (which correspond to Ease in
Anki). This resulted in too large E-factors for imported items.

This change adds an A-factor to E-factor conversion to the
importer.
2014-01-26 10:09:47 +02:00
Jussi Maatta
cdcd5eb651 Fix double newlines in items imported from SuperMemo.
When importing SuperMemo XML files, indicate to the BeautifulSoup
XML parser that the <br> tag is self-closing. This prevents it
from adding a matching </br> for every <br> tag. These extraneous
tags resulted in extra newlines in items imported from SuperMemo.

While we're at it, fix the same bug for a couple of other
self-closing HTML tags.
2014-01-26 10:06:53 +02:00
Jussi Maatta
6c6be1144b Remove unused function from SuperMemo XML importer. 2014-01-26 10:01:06 +02:00
Damien Elmes
e610776bb0 possible fix for supermemo importer (#480)
Not sure why the original author was converting angle brackets separately -
that code breaks the example provided in #480, but I'm not sure if removing it
will break other files.
2013-01-15 06:37:30 +09:00
Damien Elmes
b2457811a2 optimize imports 2012-12-22 09:17:10 +09:00
Damien Elmes
d477df8c28 merged libanki and ankiqt into single distro 2012-12-21 16:51:59 +09:00