Skip to content
Snippets Groups Projects

Move provisioning proxy steps to the new LSO endpoint

Merged Karel van Klink requested to merge feature/use-generic-provisioning-proxy-endpoint into develop
All threads resolved!
1 file
+ 1
5
Compare changes
  • Side-by-side
  • Inline
@@ -6,7 +6,6 @@
import json
import logging
from functools import partial
from http import HTTPStatus
from typing import Any
import requests
@@ -74,10 +73,7 @@ def _send_request(operation: CUDOperation, endpoint: str, parameters: dict, call
elif operation == CUDOperation.DELETE:
request = requests.delete(url, json=parameters, timeout=10000)
if not HTTPStatus.OK <= request.status_code < HTTPStatus.MULTIPLE_CHOICES:
# :term:`LSO` has returned a status code that is outside the 2xx range, and has therefore failed
logger.debug(request.content)
raise AssertionError(request.content)
request.raise_for_status()
_send_post = partial(_send_request, CUDOperation.POST)
Loading