Skip to content

Commit f20b817

Browse files
authored
fix: Check for empty master CS hostname
Added a check for empty master CS hostname before resolving IP addresses.
1 parent 02beecf commit f20b817

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/DIRAC/WorkloadManagementSystem/Utilities/PilotCStoJSONSynchronizer.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,8 @@ def exclude_master_cs_aliases(urls: list[str], master_cs_url: str) -> list[str]:
5656
- The comparison is based on IP addresses, not hostnames.
5757
"""
5858
master_cs_hostname = urlparse(master_cs_url).hostname
59+
if not master_cs_hostname:
60+
return urls
5961

6062
# Resolve IP addresses for the MasterCS hostname
6163
try:

0 commit comments

Comments
 (0)