- new per-character tokenizer that is easier to read and maintain
- OR searches now supported
- grouping with ( and ) now supported
- sorting is off by default now
- searching in html is disabled for now, but may come back later
- use ? arguments instead of named arguments to ease porting to other
platforms
- field:foo is no longer wrapped in implicit wildcards
- avoid joining notes table if it not required - about 30% faster
- fixed sql injection bug in findNids()
- commands no longer have to take care of negation themselves
- commands can return nothing to immediately flag the query as invalid
The old template handling was too complicated, and generated frequent
questions on the forums. By dropping non-active templates we can do away with
the generate cards function, and advanced users can simulate the old behaviour
by using conditional field templates.
- moved tags into json like previous changes, and dropped the unnecessary id
- added tags.py for a tag manager
- moved the tag utilities from utils into tags.py
Like the previous change, models have been moved from a separate DB table to
an entry in the deck. We need them for many operations including reviewing,
and it's easier to keep them in memory than half on disk with a cache that
gets cleared every time we .reset(). This means they are easily serialized as
well - previously they were part Python and part JSON, which made access
confusing.
Because the data is all pulled from JSON now, the instance methods have been
moved to the model registry. Eg:
model.addField(...) -> deck.models.addField(model, ...).
- IDs are now timestamped as with groups et al.
- The data field for plugins was also removed. Config info can be added to
deck.conf; larger data should be stored externally.
- Upgrading needs to be updated for the new model structure.
- HexifyID() now accepts strings as well, as our IDs get converted to strings
in the serialization process.