Anki/pylib/anki/scheduler/__init__.py
Damien Elmes ec8adf7371 move old scheduler files into scheduler/
Includes a hack that should allow existing imports to continue to work;
if this breaks things for you, please let me know.
2021-03-12 14:43:45 +10:00

21 lines
667 B
Python

# Copyright: Ankitects Pty Ltd and contributors
# License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
from __future__ import annotations
import sys
import anki.scheduler.base as _base
UnburyCurrentDeck = _base.UnburyCurrentDeck
CongratsInfo = _base.CongratsInfo
BuryOrSuspend = _base.BuryOrSuspend
# add aliases to the legacy pathnames
import anki.scheduler.v1
import anki.scheduler.v2
sys.modules["anki.sched"] = sys.modules["anki.scheduler.v1"]
sys.modules["anki.schedv2"] = sys.modules["anki.scheduler.v2"]
anki.sched = sys.modules["anki.scheduler.v1"] # type: ignore
anki.schedv2 = sys.modules["anki.scheduler.v2"] # type: ignore