Skip to content
GitLab
Explore
Projects
Groups
Snippets
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
cc68e387
Commit
cc68e387
authored
1 year ago
by
BO ZHANG
Browse files
Options
Download
Email Patches
Plain Diff
set n_try to 5 for default
parent
3c417809
dev
main
No related merge requests found
Pipeline
#2610
failed with stage
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
csst_common/utils/_retry.py
+5
-1
csst_common/utils/_retry.py
with
5 additions
and
1 deletion
+5
-1
csst_common/utils/_retry.py
+
5
-
1
View file @
cc68e387
...
...
@@ -9,7 +9,11 @@ Modified-History:
"""
def
retry
(
func
,
n_try
=
3
,
*
args
,
**
kwargs
):
def
retry
(
func
,
*
args
,
**
kwargs
):
if
"n_try"
in
kwargs
.
keys
():
n_try
=
kwargs
.
pop
(
"n_try"
)
else
:
n_try
=
5
# is DFS?
try
:
assert
func
.
__self__
.
__class__
.
__module__
.
startswith
(
"csst_dfs_api"
),
func
...
...
This diff is collapsed.
Click to expand it.
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
Menu
Explore
Projects
Groups
Snippets