fix .paths imports

This commit is contained in:
Dima Gerasimov 2019-12-21 09:48:07 +00:00
parent 3ee2deecae
commit 0415ea2560
5 changed files with 13 additions and 28 deletions

View file

@ -1,14 +1,7 @@
from functools import lru_cache
from . import paths
@lru_cache()
def stexport():
from .common import import_file
stexport_model = import_file(paths.stexport.repo / 'model.py')
return stexport_model
import mycfg.repos.stexport.model as stexport
from mycfg import paths
def get_data():
sources = [max(paths.stexport.export_dir.glob('*.json'))]
return stexport().Model(sources).site_model('stackoverflow')
return stexport.Model(sources).site_model('stackoverflow')