mirror of
https://github.com/ankitects/anki.git
synced 2025-09-24 16:56:36 -04:00
dump location of non-unicode string references
This commit is contained in:
parent
870d18dff6
commit
793b660ec3
1 changed files with 11 additions and 0 deletions
11
anki/db.py
11
anki/db.py
|
@ -39,6 +39,17 @@ except ImportError:
|
|||
from sqlalchemy import Unicode
|
||||
UnicodeText = Unicode
|
||||
|
||||
# dump location of non-unicode string
|
||||
from sqlalchemy import util
|
||||
import traceback
|
||||
oldWarn = util.warn
|
||||
def newWarn(*args, **kwargs):
|
||||
traceback.print_stack()
|
||||
oldWarn(*args, **kwargs)
|
||||
util.warn = newWarn
|
||||
|
||||
|
||||
|
||||
metadata = MetaData()
|
||||
|
||||
# this class assumes the provided session is called with transactional=False
|
||||
|
|
Loading…
Reference in a new issue