Skip to content

Commit c7b7e2a

Browse files
committed
fix: initialize pilot log lifetime in the constructor
1 parent ba5da8e commit c7b7e2a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/DIRAC/WorkloadManagementSystem/Agent/PilotLoggingAgent.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ class PilotLoggingAgent(AgentModule):
3131
def __init__(self, *args, **kwargs):
3232
"""c'tor"""
3333
super().__init__(*args, **kwargs)
34+
self.clearPilotsDelay = 30
3435

3536
def initialize(self):
3637
"""
@@ -42,7 +43,7 @@ def initialize(self):
4243
:param self: self reference
4344
"""
4445
# pilot logs lifetime in days
45-
self.clearPilotsDelay = self.am_getOption("ClearPilotsDelay", 30)
46+
self.clearPilotsDelay = self.am_getOption("ClearPilotsDelay", self.clearPilotsDelay)
4647
# configured VOs and setup
4748
res = getVOs()
4849
if not res["OK"]:

0 commit comments

Comments
 (0)