diff --git a/Py3Cache.py b/Py3Cache.py index 92791f58de77819943dd4e917bf3b135fc02d46f..cb370bb24f77135067a6edac3f208269dfa42fde 100644 --- a/Py3Cache.py +++ b/Py3Cache.py @@ -3,7 +3,7 @@ """ Python Implements Level 2 Cache Broker """ - +import os import sys import json import uuid @@ -37,7 +37,8 @@ class Py3Cache (threading.Thread): threading.Thread.__init__(self) config = configparser.ConfigParser() config.optionxform = str # 保留配置文件key的大小写设定 - config.read("config.ini") + config_path=os.path.join(os.path.split(os.path.realpath(__file__))[0],"config.ini") + config.read(config_path) self.debug = "true" == config.get("global", "debug")