Skip to content

Commit

Permalink
fix: get setup from gConfig in ComponentSupervisionAgent
Browse files Browse the repository at this point in the history
  • Loading branch information
aldbr committed Oct 11, 2023
1 parent fdddd04 commit 1e59b2f
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ def logError(self, errStr, varMsg=""):

def beginExecution(self):
"""Reload the configurations before every cycle."""
self.setup = self.am_getOption("Setup", self.setup)
self.setup = gConfig.getValue("/DIRAC/Setup", self.setup)
self.enabled = self.am_getOption("EnableFlag", self.enabled)
self.restartAgents = self.am_getOption("RestartAgents", self.restartAgents)
self.restartExecutors = self.am_getOption("RestartExecutors", self.restartExecutors)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,6 @@ def test_begin_execution(self):
self.restartAgent.accounting["Junk"]["Funk"] = 1
self.restartAgent.am_getOption = MagicMock()
getOptionCalls = [
call("Setup", self.restartAgent.setup),
call("EnableFlag", True),
call("MailTo", self.restartAgent.addressTo),
call("MailFrom", self.restartAgent.addressFrom),
Expand Down
2 changes: 0 additions & 2 deletions src/DIRAC/FrameworkSystem/ConfigTemplate.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -208,8 +208,6 @@ Agents
PollingTime = 600
# Overall enable or disable
EnableFlag = False
# Which setup to monitor
Setup = DIRAC-Production
# Email addresses receiving notifications
MailTo =
# Sender email address
Expand Down

0 comments on commit 1e59b2f

Please sign in to comment.