Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[devel] fix: use another environment variable to spot pilots running in htcondor #236

Merged
merged 1 commit into from
Mar 27, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 10 additions & 15 deletions Pilot/pilotTools.py
Original file line number Diff line number Diff line change
Expand Up @@ -271,24 +271,14 @@ def getSubmitterInfo(ceName):
flavour = "SSH%s" % batchSystemType
pilotReference = "sshslurm://" + ceName + "/" + batchSystemJobID

# Condor
if "CONDOR_JOBID" in os.environ:
batchSystemType = "HTCondor"
batchSystemJobID = os.environ["CONDOR_JOBID"]
batchSystemParameters["InfoPath"] = os.environ.get("_CONDOR_JOB_AD", "Unknown")

flavour = "SSH%s" % batchSystemType
pilotReference = "sshcondor://" + ceName + "/" + batchSystemJobID

# # CEs/Batch Systems

# HTCondor
if "HTCONDOR_JOBID" in os.environ:
if "_CONDOR_JOB_AD" in os.environ:
batchSystemType = "HTCondor"
fstagni marked this conversation as resolved.
Show resolved Hide resolved
batchSystemJobID = os.environ["HTCONDOR_JOBID"]
batchSystemJobID = None # Not available in the environment
batchSystemParameters["InfoPath"] = os.environ["_CONDOR_JOB_AD"]

flavour = "HTCondorCE"
pilotReference = "htcondorce://" + ceName + "/" + batchSystemJobID
flavour = "SSH%s" % batchSystemType
pilotReference = "sshcondor://" + ceName + "/" + os.environ.get("CONDOR_JOBID", pilotReference)

# # Local/SSH

Expand All @@ -311,6 +301,11 @@ def getSubmitterInfo(ceName):

# # CEs

# HTCondor
if "HTCONDOR_JOBID" in os.environ:
flavour = "HTCondorCE"
pilotReference = "htcondorce://" + ceName + "/" + os.environ["HTCONDOR_JOBID"]

# ARC
if "GRID_GLOBAL_JOBURL" in os.environ:
flavour = "ARC"
Expand Down
Loading