-
Notifications
You must be signed in to change notification settings - Fork 59
revise option to control number of resubmit fail jobs #545 #554
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
11fe336
8140a43
b893544
82b7262
01ffd14
56e3afe
703aa49
2c3b38a
f73e0f9
957cf4a
034c9d7
3f07742
499c691
76150bf
ef28a1b
65dca91
ffe52e1
8d7b566
8c50c4f
89d2a41
2093336
920984d
c8f5657
ef6ebeb
f56fa50
e06c648
6d6c973
dae7909
4ca179c
83644c3
b1758d9
62a3459
774b130
2ae2e62
ad6b971
d02adf6
3aca952
9fc0f84
95b8aa5
cc7efcd
99589d3
711da1d
1e0c21e
10cf5d3
416a767
e530cf6
5adce1b
4084a31
9b1c566
fc690ae
cfbc5dd
81f52a3
7bbc485
37da47c
bca9728
02f1449
c13be3b
a9fbadf
fba9574
0d2cd71
5f42bc8
bfe1615
1ded55e
4033a20
59b6139
1f514de
be99e41
415c114
ac9c1e4
d28233d
1f29674
ba5147d
7ee3919
2fb5e81
033443c
f977a7a
1787bcc
2e8b001
c56ef45
6bd72ad
57a5991
69b4a0b
e80b712
2f22fe5
4bf6a76
170b1ef
9db2abc
4ad8a82
96176dc
284f1f8
8b04937
909e595
1ee843f
6b244da
4bb42d8
e897d8a
ae8a0a3
0d6bf3d
1d0d467
08e24a6
ac7116d
558e911
c8b0198
2960443
6682e06
26a3732
77ce083
ecc93b2
bfe4356
e9d5781
2336f62
b74bf7a
eb1a730
c49374e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -29,7 +29,8 @@ def unzip_file(zip_file, out_dir="./"): | |
|
|
||
|
|
||
| class OpenAPI(Machine): | ||
| def __init__(self, context): | ||
| def __init__(self, context, **kwargs): | ||
| super().__init__(context=context, **kwargs) | ||
|
Comment on lines
+32
to
+33
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion | 🟠 Major Add type hints to comply with coding guidelines. The refactoring correctly delegates retry_count handling to the base class. However, type hints are missing from the method signature, violating the coding guideline: "Always add type hints in all Python code". Apply this diff to add type hints: - def __init__(self, context, **kwargs):
+ def __init__(self, context: BaseContext, **kwargs: Any) -> None:
super().__init__(context=context, **kwargs)Add the import if not already present: from typing import AnyAs per coding guidelines. 🤖 Prompt for AI Agents |
||
| if not found_bohriumsdk: | ||
| raise ModuleNotFoundError( | ||
| "bohriumsdk not installed. Install dpdispatcher with `pip install dpdispatcher[bohrium]`" | ||
|
|
@@ -38,7 +39,6 @@ def __init__(self, context): | |
| self.remote_profile = context.remote_profile.copy() | ||
|
|
||
| self.grouped = self.remote_profile.get("grouped", True) | ||
| self.retry_count = self.remote_profile.get("retry_count", 3) | ||
| self.ignore_exit_code = context.remote_profile.get("ignore_exit_code", True) | ||
|
|
||
| access_key = ( | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -17,6 +17,9 @@ | |
|
|
||
|
|
||
| class PBS(Machine): | ||
| # def __init__(self, **kwargs): | ||
| # super().__init__(**kwargs) | ||
|
|
||
| def gen_script(self, job): | ||
| pbs_script = super().gen_script(job) | ||
| return pbs_script | ||
|
|
@@ -188,24 +191,8 @@ def gen_script_header(self, job): | |
|
|
||
|
|
||
| class SGE(PBS): | ||
| def __init__( | ||
| self, | ||
| batch_type=None, | ||
| context_type=None, | ||
| local_root=None, | ||
| remote_root=None, | ||
| remote_profile={}, | ||
| *, | ||
| context=None, | ||
| ): | ||
| super(PBS, self).__init__( | ||
| batch_type, | ||
| context_type, | ||
| local_root, | ||
| remote_root, | ||
| remote_profile, | ||
| context=context, | ||
| ) | ||
| def __init__(self, **kwargs): | ||
| super().__init__(**kwargs) | ||
|
Comment on lines
+194
to
+195
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion | 🟠 Major Add type hints to comply with coding guidelines. The SGE constructor correctly forwards keyword arguments to the base class. However, type hints are missing, violating the coding guideline: "Always add type hints in all Python code". Apply this diff: - def __init__(self, **kwargs):
+ def __init__(self, **kwargs: Any) -> None:
super().__init__(**kwargs)Ensure the from typing import AnyAs per coding guidelines. 🤖 Prompt for AI Agents |
||
|
|
||
| def gen_script_header(self, job): | ||
| ### Ref:https://softpanorama.org/HPC/PBS_and_derivatives/Reference/pbs_command_vs_sge_commands.shtml | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion | 🟠 Major
Add type hints to comply with coding guidelines.
The refactoring correctly delegates retry_count handling to the base class by accepting and forwarding
**kwargs. However, the method signature is missing type hints, which violates the project's coding guideline: "Always add type hints in all Python code".Apply this diff to add type hints:
You may need to add the import at the top of the file if not already present:
As per coding guidelines.
🤖 Prompt for AI Agents