From 68b8eb6c3bb7ba546eae9cda12fc06a64f6e8ab8 Mon Sep 17 00:00:00 2001 From: BryantHe Date: Mon, 7 Aug 2023 13:51:47 +0800 Subject: [PATCH] fix: update command metric-config-gen --- namekoplus/command.py | 3 +++ setup.py | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/namekoplus/command.py b/namekoplus/command.py index dca776d..c923e02 100644 --- a/namekoplus/command.py +++ b/namekoplus/command.py @@ -324,6 +324,9 @@ def metric_config_gen(module, class_name_str): import sys from statsd.client.timer import Timer sys.path.append(os.getcwd()) + for root, dirs, files in os.walk(os.getcwd()): + for _dir in dirs: + sys.path.append(os.path.join(root, _dir)) # Extract information of statsd config from the class of nameko service file_name = module.split('.')[-1] diff --git a/setup.py b/setup.py index 5e06fb2..31809da 100644 --- a/setup.py +++ b/setup.py @@ -9,7 +9,7 @@ with open(path.join(here, 'README.md'), encoding='utf-8') as f: setup( name='namekoplus', - version='0.4.8', + version='0.4.9', description='A lightweight Python distributed microservice solution', long_description=long_description, long_description_content_type='text/markdown',