Skip to content

Commit 400c29b

Browse files
justin-h-loiarp102
authored andcommitted
Removing bandit/pyaml version requirements
1 parent a664187 commit 400c29b

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

kmip/services/server/auth/slugs.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ def authenticate(self,
8888
)
8989

9090
try:
91-
response = requests.get(self.users_url.format(user_id))
91+
response = requests.get(self.users_url.format(user_id), timeout=10)
9292
except Exception:
9393
raise exceptions.ConfigurationError(
9494
"A connection could not be established using the SLUGS URL."
@@ -98,7 +98,7 @@ def authenticate(self,
9898
"Unrecognized user ID: {}".format(user_id)
9999
)
100100

101-
response = requests.get(self.groups_url.format(user_id))
101+
response = requests.get(self.groups_url.format(user_id), timeout=10)
102102
if response.status_code == 404:
103103
raise exceptions.PermissionDenied(
104104
"Group information could not be retrieved for user ID: "

kmip/tests/unit/services/server/auth/test_slugs.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,10 +137,10 @@ def test_authenticate(self, mock_get_client_identity, mock_request_get):
137137

138138
mock_get_client_identity.assert_called_once_with("test")
139139
mock_request_get.assert_any_call(
140-
"http://127.0.0.1:8080/test/slugs/users/John Doe"
140+
"http://127.0.0.1:8080/test/slugs/users/John Doe", timeout=10
141141
)
142142
mock_request_get.assert_any_call(
143-
"http://127.0.0.1:8080/test/slugs/users/John Doe/groups"
143+
"http://127.0.0.1:8080/test/slugs/users/John Doe/groups", timeout=10
144144
)
145145
self.assertEqual(('John Doe', ['Group A', 'Group B']), result)
146146

test-requirements.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@ fixtures
66
mock
77
slugs
88
sphinx
9-
PyYAML<=5.2
10-
bandit==1.5.1
9+
PyYAML
10+
bandit

0 commit comments

Comments
 (0)