diff options
author | Matthias Baumgartner <dev@igsor.net> | 2023-04-05 17:22:59 +0200 |
---|---|---|
committer | Matthias Baumgartner <dev@igsor.net> | 2023-04-05 17:22:59 +0200 |
commit | 0b6b1d27756d1c02a2a667ebfc1a119081ff079f (patch) | |
tree | ed1dacee986c3b0bf1387fed58c6128616ced571 /bsie/apps/_loader.py | |
parent | ef50c1895c810d7a03bc139587a345273701cdbe (diff) | |
download | bsie-0b6b1d27756d1c02a2a667ebfc1a119081ff079f.tar.gz bsie-0b6b1d27756d1c02a2a667ebfc1a119081ff079f.tar.bz2 bsie-0b6b1d27756d1c02a2a667ebfc1a119081ff079f.zip |
config file fix
Diffstat (limited to 'bsie/apps/_loader.py')
-rw-r--r-- | bsie/apps/_loader.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/bsie/apps/_loader.py b/bsie/apps/_loader.py index 6411f10..d9ea9bb 100644 --- a/bsie/apps/_loader.py +++ b/bsie/apps/_loader.py @@ -1,5 +1,6 @@ # standard imports +import os import typing # external imports @@ -12,8 +13,7 @@ from bsie.lib.pipeline import Pipeline from bsie.reader import ReaderBuilder # constants -DEFAULT_CONFIG_FILE = 'default_config.yaml' - +DEFAULT_CONFIG_FILE = os.path.join(os.path.dirname(__file__), 'default_config.yaml') # exports __all__: typing.Sequence[str] = ( 'DEFAULT_CONFIG_FILE', @@ -23,7 +23,7 @@ __all__: typing.Sequence[str] = ( ## code ## -def load_pipeline(path: str) -> Pipeline: +def load_pipeline(path: str = DEFAULT_CONFIG_FILE) -> Pipeline: """Load a pipeline according to a config at *path*.""" # load config file with open(path, 'rt', encoding='utf-8') as ifile: |