Skip to content

Commit cf065fc

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 390dbfd commit cf065fc

File tree

9 files changed

+8
-18
lines changed

9 files changed

+8
-18
lines changed

.github/workflows/codeql.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ name: "CodeQL"
55

66
on:
77
push:
8-
branches: [ "master", "1.0", "1.1", "1.2", "1.3", "1.4", "1.5", "1.6", "1.7" ]
8+
branches: ["master", "1.0", "1.1", "1.2", "1.3", "1.4", "1.5", "1.6", "1.7"]
99
pull_request:
10-
branches: [ "master" ]
10+
branches: ["master"]
1111
schedule:
1212
- cron: "59 17 * * 6"
1313

@@ -23,7 +23,7 @@ jobs:
2323
strategy:
2424
fail-fast: false
2525
matrix:
26-
language: [ python ]
26+
language: [python]
2727

2828
steps:
2929
- name: Checkout

src/decisionengine_modules/AWS/transforms/AwsBurnRate.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ def __init__(self, config):
1717
super().__init__(config)
1818

1919
def transform(self, data_block):
20-
2120
spot_prices = self.provisioner_resource_spot_prices(data_block).fillna(0)
2221
occupancy = self.AWS_Occupancy(data_block).fillna(0)
2322

src/decisionengine_modules/GCE/transforms/GceFigureOfMerit.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ def __init__(self, config):
2222
super().__init__(config)
2323

2424
def transform(self, data_block):
25-
2625
self.logger.debug("in GceFigureOfMerit transform")
2726
performance = self.GCE_Instance_Performance(data_block)
2827
performance["PricePerformance"] = np.where(

src/decisionengine_modules/glideinwms/classads.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55

66

77
class GlideClientClassad(classadSupport.Classad):
8-
98
# Class variable: Counter for classad counter.
109
# key = (name)
1110
classad_counter = {}

src/decisionengine_modules/glideinwms/configure_gwms_frontend.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,6 @@ def get_arg_parser():
8484
############################################################
8585

8686
if __name__ == "__main__":
87-
8887
noroot_msg = "NOTE: Executing this command as user root is not allowed. Use the decisionengine user instead."
8988

9089
if os.geteuid() == 0:

src/decisionengine_modules/glideinwms/glide_frontend_element.py

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -437,7 +437,6 @@ def create_glideclient_classads(
437437
entry_name="condor",
438438
glidein_site="Unknown",
439439
):
440-
441440
if glidein_params is None:
442441
glidein_params = {}
443442
if glidein_monitors is None:
@@ -665,7 +664,7 @@ def create_glideclientglobal_classads(self, glidefactory_classad, key_builder):
665664
}
666665
for cred in credentials:
667666
if cred.advertize:
668-
for (fname, data) in cred.loaded_data:
667+
for fname, data in cred.loaded_data:
669668
classad_attrs_to_encrypt[cred.file_id(fname)] = data
670669
if hasattr(cred, "security_class"):
671670
# Convert security_class to string for factory
@@ -941,7 +940,7 @@ def count_match(self, job_types, job_type, entries):
941940
# Get group of jobs based on request cpus
942941
job_groups = jobs.groupby("RequestCpus")
943942

944-
for (req_cpus, group) in job_groups:
943+
for req_cpus, group in job_groups:
945944
# Group jobs by matching criteria: RequestCpus for now
946945
# We care about job counts for each group
947946
job_count = len(group)
@@ -1065,7 +1064,6 @@ def identify_limits_triggered(
10651064
global_total_idle_glideins,
10661065
limits_triggered,
10671066
):
1068-
10691067
# Identify the limits triggered for advertising in glideresource
10701068
if count_status["Total"] >= self.entry_max_glideins: # max_running
10711069
limits_triggered[
@@ -1123,7 +1121,6 @@ def compute_glidein_min_idle(
11231121
or (global_total_glideins >= self.global_total_max_slots)
11241122
or (global_total_idle_glideins >= self.global_total_max_slots_idle)
11251123
):
1126-
11271124
# Do not request more glideins under following conditions:
11281125
# 1. Have all the running jobs I wanted
11291126
# 2. Have enough idle vms/slots
@@ -1799,7 +1796,7 @@ def count_match_fom_bff(self, job_types, job_type, entries):
17991796

18001797
dbg_info.append(f"{len(job_groups)} job groups")
18011798

1802-
for (req_cpus, job_group) in job_groups:
1799+
for req_cpus, job_group in job_groups:
18031800
# Group jobs by matching criteria: RequestCpus for now
18041801
# We only care about job counts for each group
18051802
job_count = len(job_group)
@@ -1903,7 +1900,7 @@ def count_match_fom_dff(self, job_types, job_type, entries):
19031900
# Get group of jobs based on request cpus
19041901
job_groups = jobs.groupby("RequestCpus")
19051902

1906-
for (req_cpus, job_group) in job_groups:
1903+
for req_cpus, job_group in job_groups:
19071904
# Group jobs by matching criteria: RequestCpus for now
19081905
# We care about job counts for each group
19091906
job_count = len(job_group)
@@ -1940,7 +1937,7 @@ def count_match_fom_dff(self, job_types, job_type, entries):
19401937
# Start with entries with lowest FOM and fill them first
19411938
job_count_matched = 0
19421939

1943-
for (_fom, fom_group_entries) in fom_matches:
1940+
for _fom, fom_group_entries in fom_matches:
19441941
job_count_unmatched = job_count - job_count_matched
19451942
if job_count_unmatched > 0:
19461943
# Distribute the jobs equally among this entry group

src/decisionengine_modules/glideinwms/security.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,6 @@ def __str__(self):
227227

228228

229229
class CredentialCache:
230-
231230
# Cache the credential ids so we do not create again unless required
232231
# Specially expensive to create id for proxy which uses DN in hash
233232
def __init__(self):

src/decisionengine_modules/glideinwms/transforms/gwms_to_aws_data.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ def __init__(self, config):
2020
super().__init__(config)
2121

2222
def transform(self, datablock):
23-
2423
# Get the dataframe containing AWS entries
2524
self.logger.debug("in AWSFactoryEntryData transform")
2625
aws_entries = self.Factory_Entries(datablock).xs("AWS")

src/decisionengine_modules/glideinwms/transforms/job_clustering.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@ def __init__(self, config):
4949
)
5050

5151
def transform(self, datablock):
52-
5352
self.logger.info("*** Starting job clustering ***")
5453
# TODO not sure if metadata is propagated or if this is the right attrs to id a datablock
5554

0 commit comments

Comments
 (0)