Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
R
robo-dividend
Project
Project
Details
Activity
Releases
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wenwen.tang
robo-dividend
Commits
99e568d6
Commit
99e568d6
authored
May 30, 2025
by
stephen.wang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修正benchmark bug
parent
5f50db57
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
10 deletions
+11
-10
benchmark.py
reports/benchmark.py
+11
-10
No files found.
reports/benchmark.py
View file @
99e568d6
...
@@ -47,16 +47,17 @@ class BenchmarkAlligamReportor(RoboReportor):
...
@@ -47,16 +47,17 @@ class BenchmarkAlligamReportor(RoboReportor):
response
=
requests
.
get
(
f
'http://jdcprod.thiztech.com/api/datas/asset-value?{urlencode(params)}'
)
.
json
()
response
=
requests
.
get
(
f
'http://jdcprod.thiztech.com/api/datas/asset-value?{urlencode(params)}'
)
.
json
()
if
not
response
[
'success'
]:
if
not
response
[
'success'
]:
raise
Exception
(
f
'''request jdc alligam failed: {response['status']}'''
)
raise
Exception
(
f
'''request jdc alligam failed: {response['status']}'''
)
rb
.
batch_insert
([{
if
response
[
'body'
][
'content'
]:
'date'
:
dt
.
fromtimestamp
(
x
[
'date'
]
/
1000
),
rb
.
batch_insert
([{
'module'
:
self
.
module_name
,
'date'
:
dt
.
fromtimestamp
(
x
[
'date'
]
/
1000
),
'risk'
:
self
.
risk
,
'module'
:
self
.
module_name
,
'nav'
:
x
[
'calibrateValue'
],
'risk'
:
self
.
risk
,
'remarks'
:
json
.
dumps
({
'nav'
:
x
[
'calibrateValue'
],
'av'
:
x
[
'originValue'
],
'remarks'
:
json
.
dumps
({
'div'
:
x
[
'dividend'
]
if
'dividend'
in
x
else
0
'av'
:
x
[
'originValue'
],
},
ensure_ascii
=
False
)
'div'
:
x
[
'dividend'
]
if
'dividend'
in
x
else
0
}
for
x
in
response
[
'body'
][
'content'
]])
},
ensure_ascii
=
False
)
}
for
x
in
response
[
'body'
][
'content'
]])
if
response
[
'body'
][
'last'
]:
if
response
[
'body'
][
'last'
]:
break
break
else
:
else
:
...
...
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