From aee35ca662768fc41828dacea01eee6ac2843006 Mon Sep 17 00:00:00 2001 From: Tim Kreuzer <t.kreuzer@fz-juelich.de> Date: Tue, 20 Aug 2024 15:06:34 +0200 Subject: [PATCH] update regex to use newest dispatch hpc infos --- jsc_custom/authenticator/oauthenticator.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jsc_custom/authenticator/oauthenticator.py b/jsc_custom/authenticator/oauthenticator.py index 0f77d42..b59c609 100644 --- a/jsc_custom/authenticator/oauthenticator.py +++ b/jsc_custom/authenticator/oauthenticator.py @@ -39,7 +39,7 @@ def get_system_infos( 3. Remove systems in maintenance 4. Create and return dicts of lists for system, account, project, partition, reservation """ - s = "^([^\,]+),([^\,]+),([^\,]+),([^\,]+)" + s = "^([^\,]+),([^\,]+),([^\,]+),([^\,]+).*" c = re.compile(s) def regroup(x): @@ -948,7 +948,7 @@ class CustomGenericOAuthenticator(GenericOAuthenticator): hpc_list = ["".join(hpc_list)] for entry in hpc_list: try: - partition = re.search("[^,]+,([^,]+),[^,]+,[^,]+", entry).groups()[0] + partition = re.search("[^,]+,([^,]+),[^,]+,[^,]+.*", entry).groups()[0] except: authenticator.log.info( f"----- {authentication['name']} - Failed to check for defaults partitions: {entry} ---- {hpc_list}" -- GitLab