Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
csst-pipeline
csst_common
Commits
2fc29baa
Commit
2fc29baa
authored
Jan 13, 2026
by
BO ZHANG
🏀
Browse files
remove is_dfs in retry
parent
d51f2ba5
Pipeline
#11834
passed with stage
in 0 seconds
Changes
1
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
csst_common/utils/_retry.py
View file @
2fc29baa
...
@@ -18,15 +18,15 @@ def retry(func, *args, **kwargs):
...
@@ -18,15 +18,15 @@ def retry(func, *args, **kwargs):
n_try
=
5
n_try
=
5
# is DFS?
# is DFS?
# TODO: support DFS2
# TODO: support DFS2
is_dfs
=
func
.
__class__
.
__module__
.
startswith
(
"csst_dfs_client"
)
#
is_dfs = func.__class__.__module__.startswith("csst_dfs_client")
# start trials
# start trials
for
attempt
in
range
(
n_try
):
for
attempt
in
range
(
n_try
):
print
(
f
"Trial #
{
attempt
}
: call
{
func
}
"
)
print
(
f
"Trial #
{
attempt
}
: call
{
func
}
"
)
try
:
try
:
res
=
func
(
*
args
,
**
kwargs
)
res
=
func
(
*
args
,
**
kwargs
)
if
is_dfs
:
#
if is_dfs:
# TODO: support DFS2
#
# TODO: support DFS2
assert
res
.
success
,
res
#
assert res.success, res
return
res
return
res
except
Exception
as
e
:
except
Exception
as
e
:
# print error messages
# print error messages
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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