Spaces:
Running
Running
seanpedrickcase
commited on
Commit
·
86f6252
1
Parent(s):
d7ef72c
Hopefully now a correct STS endpoint. Updated file name check to account for double backslashes
Browse files- tools/aws_functions.py +1 -1
- tools/matcher_funcs.py +1 -1
tools/aws_functions.py
CHANGED
@@ -24,7 +24,7 @@ except Exception as e:
|
|
24 |
|
25 |
|
26 |
def get_assumed_role_info():
|
27 |
-
sts = boto3.client('sts', region_name='eu-west-2')
|
28 |
response = sts.get_caller_identity()
|
29 |
|
30 |
# Extract ARN of the assumed role
|
|
|
24 |
|
25 |
|
26 |
def get_assumed_role_info():
|
27 |
+
sts = boto3.client('sts', region_name='eu-west-2', endpoint_url='https://sts.eu-west-2.amazonaws.com')
|
28 |
response = sts.get_caller_identity()
|
29 |
|
30 |
# Extract ARN of the assumed role
|
tools/matcher_funcs.py
CHANGED
@@ -70,7 +70,7 @@ def get_file_name(in_name: str) -> str:
|
|
70 |
"""Get the name of a file from a string, handling both Windows and Unix paths."""
|
71 |
|
72 |
print("in_name: ", in_name)
|
73 |
-
match = re.search(rf'{os.sep}(?!.*{os.sep})(.*)', in_name)
|
74 |
if match:
|
75 |
matched_result = match.group(1)
|
76 |
else:
|
|
|
70 |
"""Get the name of a file from a string, handling both Windows and Unix paths."""
|
71 |
|
72 |
print("in_name: ", in_name)
|
73 |
+
match = re.search(rf'{re.escape(os.sep)}(?!.*{re.escape(os.sep)})(.*)', in_name)
|
74 |
if match:
|
75 |
matched_result = match.group(1)
|
76 |
else:
|