Skip to content

Commit a3efdfb

Browse files
committed
Merging deb/5.1.3-1 into 5.2.0
2 parents d8b8099 + 2002245 commit a3efdfb

File tree

6 files changed

+19
-10
lines changed

6 files changed

+19
-10
lines changed

psconfig/perfsonar-psconfig/bin/commands/agentctl

+7-3
Original file line numberDiff line numberDiff line change
@@ -259,9 +259,13 @@ elif len(args.values) > 0:
259259
cli.print_msg("Successfully set {} in {}".format(args.prop, config_file))
260260
elif args.unset:
261261
#unset an option
262-
del agent_conf.data[args.prop]
263-
_save_and_validate(agent_conf, config_client, cli)
264-
cli.print_msg("Successfully unset {} in {}".format(args.prop, config_file))
262+
try:
263+
del agent_conf.data[args.prop]
264+
_save_and_validate(agent_conf, config_client, cli)
265+
cli.print_msg("Successfully unset {} in {}".format(args.prop, config_file))
266+
except KeyError:
267+
cli.print_msg("{} was not set in {}. No action performed".format(args.prop, config_file))
268+
265269
else:
266270
# print current value of property
267271
_print_prop(args.prop, agent_conf.data.get(args.prop, None), cli)

psconfig/perfsonar-psconfig/psconfig/base_agent.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ def run(self):
146146
check_interval = None
147147

148148
try:
149-
check_interval = duration_to_seconds(agent_conf.check_interval())
149+
check_interval = int(duration_to_seconds(agent_conf.check_interval()))
150150
except Exception as e:
151151
self.logger.error(self.logf.format("Error parsing check-interval. Defaulting to " + str(self.check_interval_seconds) + " seconds: {}".format(e)))
152152
pass

psconfig/perfsonar-psconfig/psconfig/client/pscheduler/task_manager.py

+2-4
Original file line numberDiff line numberDiff line change
@@ -389,10 +389,8 @@ def _evaluate_task(self, tmap, need_new_task, new_start_time):
389389
if ((not old_task['task'].detail_exclusive()) #not exclusive
390390
and old_task['task'].detail_multiresult() #is multi-result
391391
and (old_task_start_ts + 15*60) < int(time.time()) #started at least 15 min ago
392-
and (
393-
(old_task['task'].detail_runs_started() is not None and (old_task['task'].detail_runs_started()== 0)) #have at no runs started (v1.1 and later)
394-
or (old_task['task'].detail_runs_started() is not None and (old_task['task'].detail_runs() <= 2)) #have less than two runs (not 1 because count bugged) (pre-v1.1)
395-
)):
392+
and (old_task['task'].detail_runs_started() is not None and (old_task['task'].detail_runs_started()== 0)) #no runs started
393+
):
396394

397395
#if background-multi, one or less runs and start time is 15 minutes (arbitrary)
398396
# in the past the start time is immediately. Fixes special cases where bgm

psconfig/perfsonar-psconfig/psconfig/pscheduler/agent.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ def _run_start(self, agent_conf):
5757
task_min_ttl_seconds = None
5858

5959
try:
60-
task_min_ttl_seconds = duration_to_seconds(agent_conf.task_min_ttl())
60+
task_min_ttl_seconds = int(duration_to_seconds(agent_conf.task_min_ttl()))
6161
except Exception as e:
6262
self.logger.error(self.logf.format("Error parsing task-min-ttl. Defaulting to " + str(self.task_min_ttl_seconds) + " seconds: {}".format(e)))
6363

psconfig/perfsonar-psconfig/psconfig/utilities/iso8601.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22
import isodate
33

44
def duration_to_seconds(iso):
5-
"""Convert an ISO 8601 string to a timdelta and return total seconds"""
5+
"""Convert an ISO 8601 string to a timdelta and return total seconds
6+
Returns float"""
67
try:
78
duration = isodate.parse_duration(iso)
89
except isodate.isoerror.ISO8601Error:

psconfig/perfsonar-psconfig/unibuild-packaging/deb/changelog

+6
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,12 @@ perfsonar-psconfig (5.2.0~a1.0-1) perfsonar-5.2-snapshot; urgency=low
44

55
-- perfSONAR developers <debian@perfsonar.net> Tue, 11 Jun 2024 18:27:11 +0200
66

7+
perfsonar-psconfig (5.1.3-1) perfsonar-5.1; urgency=low
8+
9+
* New upstream version.
10+
11+
-- perfSONAR developers <debian@perfsonar.net> Fri, 06 Sep 2024 11:41:34 -0400
12+
713
perfsonar-psconfig (5.1.2-1) perfsonar-5.1; urgency=low
814

915
* New upstream version.

0 commit comments

Comments
 (0)