Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
文鑫
/
guduo_spider
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Commit
5e498700
...
5e49870078e3f78496f4881f2f4a8951021641a7
authored
2024-12-23 15:16:14 +0800
by
wenxin
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
配置调整
1 parent
2885213e
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
4 deletions
app/application.yaml
app/config/tortoise_config.py
app/schemas/config_schema.py
app/application.yaml
View file @
5e49870
...
...
@@ -13,7 +13,7 @@ tortoise:
minsize
:
10
maxsize
:
200
connect_timeout
:
30
echo
:
True
,
echo
:
True
timezone
:
Asia/Shanghai
apps
:
models_read
:
...
...
app/config/tortoise_config.py
View file @
5e49870
...
...
@@ -7,7 +7,7 @@ import logging
logger
=
logging
.
getLogger
(
__name__
)
@functools.lru_cache
()
def
getTortoiseConfig
():
def
getTortoiseConfig
()
->
TortoiseConfig
:
logger
.
info
(
'开始加载TortoiseConfig'
)
# 获取当前文件的绝对路径
current_file_path
=
os
.
path
.
abspath
(
__file__
)
...
...
app/schemas/config_schema.py
View file @
5e49870
...
...
@@ -24,7 +24,6 @@ class Credentials(BaseModel):
maxsize
:
Optional
[
int
]
=
None
connect_timeout
:
Optional
[
int
]
=
None
echo
:
Optional
[
bool
]
=
None
timezone
:
str
class
Connection
(
BaseModel
):
...
...
@@ -49,4 +48,4 @@ class Port(BaseModel):
class
AppConfig
(
BaseModel
):
server
:
Port
getSpider
:
Dict
[
str
,
int
]
getSpider
:
Dict
[
str
,
int
]
...
...
Please
register
or
sign in
to post a comment