Browse Source

Delay import to prevent installation crash on windows

pull/184/head
Oliverpool 9 years ago
parent
commit
22d768a6ed
  1. 3
      patacrep/utils.py

3
patacrep/utils.py

@ -2,8 +2,6 @@
from collections import UserDict from collections import UserDict
import yaml
from patacrep import encoding, errors, pkg_datapath, Rx from patacrep import encoding, errors, pkg_datapath, Rx
class DictOfDict(UserDict): class DictOfDict(UserDict):
@ -103,6 +101,7 @@ def validate_config_schema(config):
data = config.copy() data = config.copy()
schema_path = pkg_datapath('templates', 'songbook_schema.yml') schema_path = pkg_datapath('templates', 'songbook_schema.yml')
import yaml
with encoding.open_read(schema_path) as schema_file: with encoding.open_read(schema_path) as schema_file:
schema_struct = yaml.load(schema_file) schema_struct = yaml.load(schema_file)
schema_struct = remove_keys(schema_struct, ['_description']) schema_struct = remove_keys(schema_struct, ['_description'])

Loading…
Cancel
Save