Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
doudian-py
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
baiquan
doudian-py
Commits
d7c649a4
Commit
d7c649a4
authored
Jul 01, 2025
by
baiquan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改类目接口异常判断
parent
47c7c0ee
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
task_worker.py
+4
-3
No files found.
task_worker.py
View file @
d7c649a4
...
...
@@ -198,7 +198,8 @@ def execute_get_schema(headers: dict, proxy_url: str, category_id: str):
}
elif
response
.
json
()
.
get
(
'code'
)
==
10004
or
response
.
json
()
.
get
(
'code'
)
==
10008
:
raise
CookiesExpiredError
(
data
=
response
.
text
)
raise
AppError
(
msg
=
response
.
json
()
.
get
(
'message'
),
data
=
response
.
text
)
logger
.
error
(
f
'获取类目参数异常-->{response.text}'
)
raise
AppError
(
msg
=
response
.
json
()
.
get
(
'msg'
),
data
=
response
.
text
)
except
AppError
as
e
:
logger
.
error
(
f
'获取类目参数失败-->{e.msg}'
)
...
...
@@ -209,10 +210,10 @@ def execute_get_schema(headers: dict, proxy_url: str, category_id: str):
'error_type'
:
type
(
e
)
.
__name__
}
except
Exception
as
e
:
logger
.
error
(
f
'获取类目参数
失败
-->{e}'
)
logger
.
error
(
f
'获取类目参数
错误
-->{e}'
)
return
{
'code'
:
500
,
'msg'
:
f
'获取类目参数
失败
:{e}'
,
'msg'
:
f
'获取类目参数
错误
:{e}'
,
'data'
:
None
,
'error_type'
:
'InternalError'
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment