@@ -27,14 +27,15 @@ def to_gres_options(stdout):
2727
2828 [1] https://osc.github.io/ood-documentation/latest/how-tos/app-development/interactive/form-widgets.html#form-widgets
2929 [2] https://slurm.schedmd.com/srun.html#OPT_gres
30- """
31- gres_data = (
32- {}
33- ) # k=gres_opt, v=[label, max_count] # where gres_opt is what would be passed to --gres
30+ """ # noqa: E501 pylint: disable=line-too-long
31+
32+ gres_data = {}
33+ # key=gres_opt, what would be passed to --gres
34+ # value=[label, max_count]
3435 gres_data ["none" ] = ["None" , 0 ]
3536
3637 for line in stdout .splitlines ():
37- partition , gres_definitions = (
38+ partition , gres_definitions = ( # pylint: disable=unused-variable
3839 line .split ()
3940 ) # e.g. 'part1 gpu:H200:8(S:0-1),test:foo:1', or 'part2 (null)'
4041 for gres in gres_definitions .split ("," ):
@@ -58,7 +59,7 @@ def to_gres_options(stdout):
5859 gres_data [gres_opt ][1 ] = gres_count
5960
6061 gres_options = []
61- for gres_opt in gres_data :
62+ for gres_opt in gres_data : # pylint: disable=consider-using-dict-items
6263 max_count = gres_data [gres_opt ][1 ]
6364 label = gres_data [gres_opt ][0 ]
6465 if gres_opt != "none" :
@@ -68,6 +69,7 @@ def to_gres_options(stdout):
6869
6970
7071# pylint: disable=useless-object-inheritance
72+ # pylint: disable=too-few-public-methods
7173class FilterModule (object ):
7274 """Ansible core jinja2 filters"""
7375
0 commit comments