always return str in aqt_data_folder()
This commit is contained in:
parent
aea0a6fcc6
commit
99140f6023
@ -28,11 +28,11 @@ def aqt_data_folder() -> str:
|
|||||||
dir = Path(os.path.dirname(__file__))
|
dir = Path(os.path.dirname(__file__))
|
||||||
dir = dir.parent.joinpath("aqt_data")
|
dir = dir.parent.joinpath("aqt_data")
|
||||||
if os.path.exists(dir):
|
if os.path.exists(dir):
|
||||||
return dir
|
return str(dir)
|
||||||
# wheel install?
|
# wheel install?
|
||||||
dir = os.path.join(sys.prefix, "aqt_data")
|
dir2 = os.path.join(sys.prefix, "aqt_data")
|
||||||
if os.path.exists(dir):
|
if os.path.exists(dir2):
|
||||||
return dir
|
return dir2
|
||||||
raise Exception("data folder not found")
|
raise Exception("data folder not found")
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user