faster-app 0.0.1__py3-none-any.whl → 0.0.2__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
faster_app/__init__.py CHANGED
@@ -9,7 +9,7 @@ Faster API - 一个轻量级的 Python Web 框架
9
9
  - 数据库连接管理 (tortoise_init)
10
10
  """
11
11
 
12
- __version__ = "0.0.1"
12
+ __version__ = "0.0.2"
13
13
  __author__ = "peizhenfei"
14
14
  __email__ = "peizhenfei@hotmail.com"
15
15
 
faster_app/base.py CHANGED
@@ -7,6 +7,7 @@ from typing import Dict, List
7
7
  class DiscoverBase(object):
8
8
  INSTANCE_TYPE = None
9
9
  TARGETS: List[Dict[str, str]] = []
10
+ FASTER_APP_PATH = os.path.dirname(os.path.dirname(__file__))
10
11
 
11
12
  def discover(self) -> List[type]:
12
13
  """
@@ -16,7 +16,7 @@ class CommandDiscover(DiscoverBase):
16
16
  "skip_files": [],
17
17
  },
18
18
  {
19
- "directory": "commands/builtins",
19
+ "directory": f"{DiscoverBase.FASTER_APP_PATH}/commands/builtins",
20
20
  "filename": None,
21
21
  "skip_dirs": ["__pycache__"],
22
22
  "skip_files": [],
@@ -12,7 +12,7 @@ class RoutesDiscover(DiscoverBase):
12
12
  "skip_files": [],
13
13
  },
14
14
  {
15
- "directory": "routes/builtins",
15
+ "directory": f"{DiscoverBase.FASTER_APP_PATH}/routes/builtins",
16
16
  "filename": None,
17
17
  "skip_dirs": ["__pycache__"],
18
18
  "skip_files": [],
@@ -11,7 +11,7 @@ class DefaultSettings(BaseSettings):
11
11
 
12
12
  # 基础配置
13
13
  PROJECT_NAME: str = "Faster API"
14
- VERSION: str = "0.0.1"
14
+ VERSION: str = "0.0.2"
15
15
  DEBUG: bool = True
16
16
 
17
17
  # Server 配置
@@ -20,7 +20,7 @@ class SettingsDiscover(DiscoverBase):
20
20
  "skip_files": [],
21
21
  },
22
22
  {
23
- "directory": "settings/builtins",
23
+ "directory": f"{DiscoverBase.FASTER_APP_PATH}/settings/builtins",
24
24
  "filename": "settings.py",
25
25
  "skip_dirs": ["__pycache__"],
26
26
  "skip_files": [],