Skip to content

Push on development #3188

Push on development

Push on development #3188

GitHub Actions / JUnit Test Report failed Oct 18, 2024 in 0s

835 tests run, 825 passed, 6 skipped, 4 failed.

Annotations

Check failure on line 105 in app/tests/e2e/test_did_exchange.py

See this annotation in the file changed.

@github-actions github-actions / JUnit Test Report

test_did_exchange.test_create_did_exchange_request[clean-clean-True-None-False]

fastapi.exceptions.HTTPException: 500: {"detail":"Internal Server Error"}
Raw output
self = <shared.util.rich_async_client.RichAsyncClient object at 0x7f47b55f07a0>
url = '/v1/connections/2db8231b-d345-4e19-bba8-f7b206a8569b', kwargs = {}
response = <Response [500 Internal Server Error]>, code = 500
message = '{"detail":"Internal Server Error"}'
log_message = 'Tenant alice_PUKYR - HTTP DELETE `/v1/connections/2db8231b-d345-4e19-bba8-f7b206a8569b` failed. Status code: 500. Response: `{"detail":"Internal Server Error"}`.'

    async def delete(self, url: str, **kwargs) -> Response:
        try:
            response = await super().delete(url, **kwargs)
            if self.raise_status_error:
>               response.raise_for_status()

shared/util/rich_async_client.py:61: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <Response [500 Internal Server Error]>

    def raise_for_status(self) -> Response:
        """
        Raise the `HTTPStatusError` if one occurred.
        """
        request = self._request
        if request is None:
            raise RuntimeError(
                "Cannot call `raise_for_status` as the request "
                "instance has not been set on this response."
            )
    
        if self.is_success:
            return self
    
        if self.has_redirect_location:
            message = (
                "{error_type} '{0.status_code} {0.reason_phrase}' for url '{0.url}'\n"
                "Redirect location: '{0.headers[location]}'\n"
                "For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/{0.status_code}"
            )
        else:
            message = (
                "{error_type} '{0.status_code} {0.reason_phrase}' for url '{0.url}'\n"
                "For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/{0.status_code}"
            )
    
        status_class = self.status_code // 100
        error_types = {
            1: "Informational response",
            3: "Redirect response",
            4: "Client error",
            5: "Server error",
        }
        error_type = error_types.get(status_class, "Invalid status code")
        message = message.format(self, error_type=error_type)
>       raise HTTPStatusError(message, request=request, response=self)
E       httpx.HTTPStatusError: Server error '500 Internal Server Error' for url 'https://governance-tenant-web.cloudapi.dev.didxtech.com/tenant/v1/connections/2db8231b-d345-4e19-bba8-f7b206a8569b'
E       For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/500

/usr/local/lib/python3.12/site-packages/httpx/_models.py:763: HTTPStatusError

The above exception was the direct cause of the following exception:

alice_member_client = <shared.util.rich_async_client.RichAsyncClient object at 0x7f47b55f07a0>
faber_client = <shared.util.rich_async_client.RichAsyncClient object at 0x7f47b593e0c0>
alice_acapy_client = <aries_cloudcontroller.acapy_client.AcaPyClient object at 0x7f47c451d460>
faber_acapy_client = <aries_cloudcontroller.acapy_client.AcaPyClient object at 0x7f47b5d36cf0>
use_did = True, use_did_method = None, use_public_did = False

    @pytest.mark.anyio
    @pytest.mark.parametrize(
        "use_did,use_did_method,use_public_did",
        [
            (None, None, False),
            (True, None, False),
            (None, "did:peer:2", False),
            (None, "did:peer:4", False),
            (True, "did:peer:4", False),
            (None, None, True),
        ],
    )
    async def test_create_did_exchange_request(
        alice_member_client: RichAsyncClient,
        faber_client: RichAsyncClient,
        alice_acapy_client: AcaPyClient,
        faber_acapy_client: AcaPyClient,
        use_did: Optional[str],
        use_did_method: Optional[str],
        use_public_did: bool,
    ):
        faber_public_did = await acapy_wallet.get_public_did(controller=faber_acapy_client)
    
        request_data = {"their_public_did": qualified_did_sov(faber_public_did.did)}
    
        if use_did:
            new_did = await acapy_wallet.create_did(controller=alice_acapy_client)
            request_data["use_did"] = new_did.did
    
        if use_did_method:
            request_data["use_did_method"] = use_did_method
    
        if use_public_did:
            request_data["use_public_did"] = use_public_did
    
        if use_public_did:  # Alice doesn't have a public DID
            with pytest.raises(HTTPException) as exc_info:
                response = await alice_member_client.post(
                    f"{CONNECTIONS_BASE_PATH}/did-exchange/create-request",
                    params=request_data,
                )
            assert exc_info.value.status_code == 400
            assert exc_info.value.detail == """{"detail":"No public DID configured."}"""
    
        elif use_did and use_did_method:
            with pytest.raises(HTTPException) as exc_info:
                await alice_member_client.post(
                    f"{CONNECTIONS_BASE_PATH}/did-exchange/create-request",
                    params=request_data,
                )
            assert exc_info.value.status_code == 400
            assert (
                exc_info.value.detail
                == """{"detail":"Cannot specify both use_did and use_did_method."}"""
            )
        else:
            response = await alice_member_client.post(
                f"{CONNECTIONS_BASE_PATH}/did-exchange/create-request", params=request_data
            )
            assert response.status_code == 200
            connection_record = response.json()
            assert_that(connection_record).contains("connection_id", "state")
            assert_that(connection_record["state"]).is_equal_to("request-sent")
    
            alice_connection_id = connection_record["connection_id"]
            alice_did = connection_record["my_did"]
    
            try:
                # Due to auto-accepts, Alice's connection is complete
                assert await check_webhook_state(
                    alice_member_client,
                    topic="connections",
                    state="completed",
                    filter_map={"connection_id": alice_connection_id},
                )
                # Faber now has a complete connection too
                assert await check_webhook_state(
                    faber_client,
                    topic="connections",
                    state="completed",
                    filter_map={"their_did": alice_did},
                )
            finally:
                await asyncio.sleep(1)  # Short sleep assists in avoiding 500 error
                # Delete connection records:
>               await alice_member_client.delete(
                    f"{CONNECTIONS_BASE_PATH}/{alice_connection_id}"
                )

app/tests/e2e/test_did_exchange.py:105: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <shared.util.rich_async_client.RichAsyncClient object at 0x7f47b55f07a0>
url = '/v1/connections/2db8231b-d345-4e19-bba8-f7b206a8569b', kwargs = {}
response = <Response [500 Internal Server Error]>, code = 500
message = '{"detail":"Internal Server Error"}'
log_message = 'Tenant alice_PUKYR - HTTP DELETE `/v1/connections/2db8231b-d345-4e19-bba8-f7b206a8569b` failed. Status code: 500. Response: `{"detail":"Internal Server Error"}`.'

    async def delete(self, url: str, **kwargs) -> Response:
        try:
            response = await super().delete(url, **kwargs)
            if self.raise_status_error:
                response.raise_for_status()
        except HTTPStatusError as e:
            code = e.response.status_code
            message = e.response.text
            log_message = f"{self.name} DELETE `{url}` failed. Status code: {code}. Response: `{message}`."
            logger.error(log_message)
    
>           raise HTTPException(status_code=code, detail=message) from e
E           fastapi.exceptions.HTTPException: 500: {"detail":"Internal Server Error"}

shared/util/rich_async_client.py:68: HTTPException

Check failure on line 105 in app/tests/e2e/test_did_exchange.py

See this annotation in the file changed.

@github-actions github-actions / JUnit Test Report

test_did_exchange.test_create_did_exchange_request[clean-clean-None-did:peer:2-False]

fastapi.exceptions.HTTPException: 500: {"detail":"Internal Server Error"}
Raw output
self = <shared.util.rich_async_client.RichAsyncClient object at 0x7f47b596c500>
url = '/v1/connections/f333c426-a3ad-42f9-a126-fdf77438ce66', kwargs = {}
response = <Response [500 Internal Server Error]>, code = 500
message = '{"detail":"Internal Server Error"}'
log_message = 'Tenant alice_AGSGF - HTTP DELETE `/v1/connections/f333c426-a3ad-42f9-a126-fdf77438ce66` failed. Status code: 500. Response: `{"detail":"Internal Server Error"}`.'

    async def delete(self, url: str, **kwargs) -> Response:
        try:
            response = await super().delete(url, **kwargs)
            if self.raise_status_error:
>               response.raise_for_status()

shared/util/rich_async_client.py:61: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <Response [500 Internal Server Error]>

    def raise_for_status(self) -> Response:
        """
        Raise the `HTTPStatusError` if one occurred.
        """
        request = self._request
        if request is None:
            raise RuntimeError(
                "Cannot call `raise_for_status` as the request "
                "instance has not been set on this response."
            )
    
        if self.is_success:
            return self
    
        if self.has_redirect_location:
            message = (
                "{error_type} '{0.status_code} {0.reason_phrase}' for url '{0.url}'\n"
                "Redirect location: '{0.headers[location]}'\n"
                "For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/{0.status_code}"
            )
        else:
            message = (
                "{error_type} '{0.status_code} {0.reason_phrase}' for url '{0.url}'\n"
                "For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/{0.status_code}"
            )
    
        status_class = self.status_code // 100
        error_types = {
            1: "Informational response",
            3: "Redirect response",
            4: "Client error",
            5: "Server error",
        }
        error_type = error_types.get(status_class, "Invalid status code")
        message = message.format(self, error_type=error_type)
>       raise HTTPStatusError(message, request=request, response=self)
E       httpx.HTTPStatusError: Server error '500 Internal Server Error' for url 'https://governance-tenant-web.cloudapi.dev.didxtech.com/tenant/v1/connections/f333c426-a3ad-42f9-a126-fdf77438ce66'
E       For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/500

/usr/local/lib/python3.12/site-packages/httpx/_models.py:763: HTTPStatusError

The above exception was the direct cause of the following exception:

alice_member_client = <shared.util.rich_async_client.RichAsyncClient object at 0x7f47b596c500>
faber_client = <shared.util.rich_async_client.RichAsyncClient object at 0x7f47b593e0c0>
alice_acapy_client = <aries_cloudcontroller.acapy_client.AcaPyClient object at 0x7f47b596ecf0>
faber_acapy_client = <aries_cloudcontroller.acapy_client.AcaPyClient object at 0x7f47b596fe90>
use_did = None, use_did_method = 'did:peer:2', use_public_did = False

    @pytest.mark.anyio
    @pytest.mark.parametrize(
        "use_did,use_did_method,use_public_did",
        [
            (None, None, False),
            (True, None, False),
            (None, "did:peer:2", False),
            (None, "did:peer:4", False),
            (True, "did:peer:4", False),
            (None, None, True),
        ],
    )
    async def test_create_did_exchange_request(
        alice_member_client: RichAsyncClient,
        faber_client: RichAsyncClient,
        alice_acapy_client: AcaPyClient,
        faber_acapy_client: AcaPyClient,
        use_did: Optional[str],
        use_did_method: Optional[str],
        use_public_did: bool,
    ):
        faber_public_did = await acapy_wallet.get_public_did(controller=faber_acapy_client)
    
        request_data = {"their_public_did": qualified_did_sov(faber_public_did.did)}
    
        if use_did:
            new_did = await acapy_wallet.create_did(controller=alice_acapy_client)
            request_data["use_did"] = new_did.did
    
        if use_did_method:
            request_data["use_did_method"] = use_did_method
    
        if use_public_did:
            request_data["use_public_did"] = use_public_did
    
        if use_public_did:  # Alice doesn't have a public DID
            with pytest.raises(HTTPException) as exc_info:
                response = await alice_member_client.post(
                    f"{CONNECTIONS_BASE_PATH}/did-exchange/create-request",
                    params=request_data,
                )
            assert exc_info.value.status_code == 400
            assert exc_info.value.detail == """{"detail":"No public DID configured."}"""
    
        elif use_did and use_did_method:
            with pytest.raises(HTTPException) as exc_info:
                await alice_member_client.post(
                    f"{CONNECTIONS_BASE_PATH}/did-exchange/create-request",
                    params=request_data,
                )
            assert exc_info.value.status_code == 400
            assert (
                exc_info.value.detail
                == """{"detail":"Cannot specify both use_did and use_did_method."}"""
            )
        else:
            response = await alice_member_client.post(
                f"{CONNECTIONS_BASE_PATH}/did-exchange/create-request", params=request_data
            )
            assert response.status_code == 200
            connection_record = response.json()
            assert_that(connection_record).contains("connection_id", "state")
            assert_that(connection_record["state"]).is_equal_to("request-sent")
    
            alice_connection_id = connection_record["connection_id"]
            alice_did = connection_record["my_did"]
    
            try:
                # Due to auto-accepts, Alice's connection is complete
                assert await check_webhook_state(
                    alice_member_client,
                    topic="connections",
                    state="completed",
                    filter_map={"connection_id": alice_connection_id},
                )
                # Faber now has a complete connection too
                assert await check_webhook_state(
                    faber_client,
                    topic="connections",
                    state="completed",
                    filter_map={"their_did": alice_did},
                )
            finally:
                await asyncio.sleep(1)  # Short sleep assists in avoiding 500 error
                # Delete connection records:
>               await alice_member_client.delete(
                    f"{CONNECTIONS_BASE_PATH}/{alice_connection_id}"
                )

app/tests/e2e/test_did_exchange.py:105: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <shared.util.rich_async_client.RichAsyncClient object at 0x7f47b596c500>
url = '/v1/connections/f333c426-a3ad-42f9-a126-fdf77438ce66', kwargs = {}
response = <Response [500 Internal Server Error]>, code = 500
message = '{"detail":"Internal Server Error"}'
log_message = 'Tenant alice_AGSGF - HTTP DELETE `/v1/connections/f333c426-a3ad-42f9-a126-fdf77438ce66` failed. Status code: 500. Response: `{"detail":"Internal Server Error"}`.'

    async def delete(self, url: str, **kwargs) -> Response:
        try:
            response = await super().delete(url, **kwargs)
            if self.raise_status_error:
                response.raise_for_status()
        except HTTPStatusError as e:
            code = e.response.status_code
            message = e.response.text
            log_message = f"{self.name} DELETE `{url}` failed. Status code: {code}. Response: `{message}`."
            logger.error(log_message)
    
>           raise HTTPException(status_code=code, detail=message) from e
E           fastapi.exceptions.HTTPException: 500: {"detail":"Internal Server Error"}

shared/util/rich_async_client.py:68: HTTPException

Check failure on line 105 in app/tests/e2e/test_did_exchange.py

See this annotation in the file changed.

@github-actions github-actions / JUnit Test Report

test_did_exchange.test_create_did_exchange_request[clean-clean-None-did:peer:4-False]

fastapi.exceptions.HTTPException: 500: {"detail":"Internal Server Error"}
Raw output
self = <shared.util.rich_async_client.RichAsyncClient object at 0x7f47b592d3d0>
url = '/v1/connections/87d87f37-2376-4787-9fd5-b7ad18194424', kwargs = {}
response = <Response [500 Internal Server Error]>, code = 500
message = '{"detail":"Internal Server Error"}'
log_message = 'Tenant alice_JGTOB - HTTP DELETE `/v1/connections/87d87f37-2376-4787-9fd5-b7ad18194424` failed. Status code: 500. Response: `{"detail":"Internal Server Error"}`.'

    async def delete(self, url: str, **kwargs) -> Response:
        try:
            response = await super().delete(url, **kwargs)
            if self.raise_status_error:
>               response.raise_for_status()

shared/util/rich_async_client.py:61: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <Response [500 Internal Server Error]>

    def raise_for_status(self) -> Response:
        """
        Raise the `HTTPStatusError` if one occurred.
        """
        request = self._request
        if request is None:
            raise RuntimeError(
                "Cannot call `raise_for_status` as the request "
                "instance has not been set on this response."
            )
    
        if self.is_success:
            return self
    
        if self.has_redirect_location:
            message = (
                "{error_type} '{0.status_code} {0.reason_phrase}' for url '{0.url}'\n"
                "Redirect location: '{0.headers[location]}'\n"
                "For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/{0.status_code}"
            )
        else:
            message = (
                "{error_type} '{0.status_code} {0.reason_phrase}' for url '{0.url}'\n"
                "For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/{0.status_code}"
            )
    
        status_class = self.status_code // 100
        error_types = {
            1: "Informational response",
            3: "Redirect response",
            4: "Client error",
            5: "Server error",
        }
        error_type = error_types.get(status_class, "Invalid status code")
        message = message.format(self, error_type=error_type)
>       raise HTTPStatusError(message, request=request, response=self)
E       httpx.HTTPStatusError: Server error '500 Internal Server Error' for url 'https://governance-tenant-web.cloudapi.dev.didxtech.com/tenant/v1/connections/87d87f37-2376-4787-9fd5-b7ad18194424'
E       For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/500

/usr/local/lib/python3.12/site-packages/httpx/_models.py:763: HTTPStatusError

The above exception was the direct cause of the following exception:

alice_member_client = <shared.util.rich_async_client.RichAsyncClient object at 0x7f47b592d3d0>
faber_client = <shared.util.rich_async_client.RichAsyncClient object at 0x7f47b593e0c0>
alice_acapy_client = <aries_cloudcontroller.acapy_client.AcaPyClient object at 0x7f47b592e960>
faber_acapy_client = <aries_cloudcontroller.acapy_client.AcaPyClient object at 0x7f47b592e420>
use_did = None, use_did_method = 'did:peer:4', use_public_did = False

    @pytest.mark.anyio
    @pytest.mark.parametrize(
        "use_did,use_did_method,use_public_did",
        [
            (None, None, False),
            (True, None, False),
            (None, "did:peer:2", False),
            (None, "did:peer:4", False),
            (True, "did:peer:4", False),
            (None, None, True),
        ],
    )
    async def test_create_did_exchange_request(
        alice_member_client: RichAsyncClient,
        faber_client: RichAsyncClient,
        alice_acapy_client: AcaPyClient,
        faber_acapy_client: AcaPyClient,
        use_did: Optional[str],
        use_did_method: Optional[str],
        use_public_did: bool,
    ):
        faber_public_did = await acapy_wallet.get_public_did(controller=faber_acapy_client)
    
        request_data = {"their_public_did": qualified_did_sov(faber_public_did.did)}
    
        if use_did:
            new_did = await acapy_wallet.create_did(controller=alice_acapy_client)
            request_data["use_did"] = new_did.did
    
        if use_did_method:
            request_data["use_did_method"] = use_did_method
    
        if use_public_did:
            request_data["use_public_did"] = use_public_did
    
        if use_public_did:  # Alice doesn't have a public DID
            with pytest.raises(HTTPException) as exc_info:
                response = await alice_member_client.post(
                    f"{CONNECTIONS_BASE_PATH}/did-exchange/create-request",
                    params=request_data,
                )
            assert exc_info.value.status_code == 400
            assert exc_info.value.detail == """{"detail":"No public DID configured."}"""
    
        elif use_did and use_did_method:
            with pytest.raises(HTTPException) as exc_info:
                await alice_member_client.post(
                    f"{CONNECTIONS_BASE_PATH}/did-exchange/create-request",
                    params=request_data,
                )
            assert exc_info.value.status_code == 400
            assert (
                exc_info.value.detail
                == """{"detail":"Cannot specify both use_did and use_did_method."}"""
            )
        else:
            response = await alice_member_client.post(
                f"{CONNECTIONS_BASE_PATH}/did-exchange/create-request", params=request_data
            )
            assert response.status_code == 200
            connection_record = response.json()
            assert_that(connection_record).contains("connection_id", "state")
            assert_that(connection_record["state"]).is_equal_to("request-sent")
    
            alice_connection_id = connection_record["connection_id"]
            alice_did = connection_record["my_did"]
    
            try:
                # Due to auto-accepts, Alice's connection is complete
                assert await check_webhook_state(
                    alice_member_client,
                    topic="connections",
                    state="completed",
                    filter_map={"connection_id": alice_connection_id},
                )
                # Faber now has a complete connection too
                assert await check_webhook_state(
                    faber_client,
                    topic="connections",
                    state="completed",
                    filter_map={"their_did": alice_did},
                )
            finally:
                await asyncio.sleep(1)  # Short sleep assists in avoiding 500 error
                # Delete connection records:
>               await alice_member_client.delete(
                    f"{CONNECTIONS_BASE_PATH}/{alice_connection_id}"
                )

app/tests/e2e/test_did_exchange.py:105: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <shared.util.rich_async_client.RichAsyncClient object at 0x7f47b592d3d0>
url = '/v1/connections/87d87f37-2376-4787-9fd5-b7ad18194424', kwargs = {}
response = <Response [500 Internal Server Error]>, code = 500
message = '{"detail":"Internal Server Error"}'
log_message = 'Tenant alice_JGTOB - HTTP DELETE `/v1/connections/87d87f37-2376-4787-9fd5-b7ad18194424` failed. Status code: 500. Response: `{"detail":"Internal Server Error"}`.'

    async def delete(self, url: str, **kwargs) -> Response:
        try:
            response = await super().delete(url, **kwargs)
            if self.raise_status_error:
                response.raise_for_status()
        except HTTPStatusError as e:
            code = e.response.status_code
            message = e.response.text
            log_message = f"{self.name} DELETE `{url}` failed. Status code: {code}. Response: `{message}`."
            logger.error(log_message)
    
>           raise HTTPException(status_code=code, detail=message) from e
E           fastapi.exceptions.HTTPException: 500: {"detail":"Internal Server Error"}

shared/util/rich_async_client.py:68: HTTPException

Check failure on line 85 in app/tests/e2e/test_did_rotate.py

See this annotation in the file changed.

@github-actions github-actions / JUnit Test Report

test_did_rotate.test_hangup_did_rotation[clean-clean]

fastapi.exceptions.HTTPException: 500: {"detail":"Internal Server Error"}
Raw output
self = <shared.util.rich_async_client.RichAsyncClient object at 0x7f8ffcf3ae40>
url = '/v1/connections/did-rotate/hangup'
kwargs = {'params': {'connection_id': '1034d15b-f3b8-402f-9860-02da68cd124d'}}
response = <Response [500 Internal Server Error]>, code = 500
message = '{"detail":"Internal Server Error"}'
log_message = 'Tenant alice_BHPCW - HTTP POST `/v1/connections/did-rotate/hangup` failed. Status code: 500. Response: `{"detail":"Internal Server Error"}`.'

    async def post(self, url: str, **kwargs) -> Response:
        try:
            response = await super().post(url, **kwargs)
            if self.raise_status_error:
>               response.raise_for_status()  # Raise exception for 4xx and 5xx status codes

shared/util/rich_async_client.py:33: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <Response [500 Internal Server Error]>

    def raise_for_status(self) -> Response:
        """
        Raise the `HTTPStatusError` if one occurred.
        """
        request = self._request
        if request is None:
            raise RuntimeError(
                "Cannot call `raise_for_status` as the request "
                "instance has not been set on this response."
            )
    
        if self.is_success:
            return self
    
        if self.has_redirect_location:
            message = (
                "{error_type} '{0.status_code} {0.reason_phrase}' for url '{0.url}'\n"
                "Redirect location: '{0.headers[location]}'\n"
                "For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/{0.status_code}"
            )
        else:
            message = (
                "{error_type} '{0.status_code} {0.reason_phrase}' for url '{0.url}'\n"
                "For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/{0.status_code}"
            )
    
        status_class = self.status_code // 100
        error_types = {
            1: "Informational response",
            3: "Redirect response",
            4: "Client error",
            5: "Server error",
        }
        error_type = error_types.get(status_class, "Invalid status code")
        message = message.format(self, error_type=error_type)
>       raise HTTPStatusError(message, request=request, response=self)
E       httpx.HTTPStatusError: Server error '500 Internal Server Error' for url 'https://governance-tenant-web.cloudapi.dev.didxtech.com/tenant/v1/connections/did-rotate/hangup?connection_id=1034d15b-f3b8-402f-9860-02da68cd124d'
E       For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/500

/usr/local/lib/python3.12/site-packages/httpx/_models.py:763: HTTPStatusError

The above exception was the direct cause of the following exception:

alice_member_client = <shared.util.rich_async_client.RichAsyncClient object at 0x7f8ffcf3ae40>
faber_client = <shared.util.rich_async_client.RichAsyncClient object at 0x7f8ffcf56750>
faber_acapy_client = <aries_cloudcontroller.acapy_client.AcaPyClient object at 0x7f8ffcf38740>

    @pytest.mark.anyio
    async def test_hangup_did_rotation(
        alice_member_client: RichAsyncClient,
        faber_client: RichAsyncClient,
        faber_acapy_client: AcaPyClient,
    ):
        # First, create did-exchange connections between Alice and Faber:
        faber_public_did = await acapy_wallet.get_public_did(controller=faber_acapy_client)
    
        request_data = {"their_public_did": qualified_did_sov(faber_public_did.did)}
        response = await alice_member_client.post(
            f"{CONNECTIONS_BASE_PATH}/did-exchange/create-request", params=request_data
        )
        connection_record = response.json()
    
        alice_connection_id = connection_record["connection_id"]
        alice_did = connection_record["my_did"]
        assert await check_webhook_state(
            alice_member_client,
            topic="connections",
            state="completed",
            filter_map={"connection_id": alice_connection_id},
        )
    
        faber_event = await check_webhook_state(
            faber_client,
            topic="connections",
            state="completed",
            filter_map={"their_did": alice_did},
        )
        faber_connection_id = faber_event["connection_id"]
    
        # Hangup the DID rotation
>       hangup_response = await alice_member_client.post(
            f"{CONNECTIONS_BASE_PATH}/did-rotate/hangup",
            params={"connection_id": alice_connection_id},
        )

app/tests/e2e/test_did_rotate.py:85: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <shared.util.rich_async_client.RichAsyncClient object at 0x7f8ffcf3ae40>
url = '/v1/connections/did-rotate/hangup'
kwargs = {'params': {'connection_id': '1034d15b-f3b8-402f-9860-02da68cd124d'}}
response = <Response [500 Internal Server Error]>, code = 500
message = '{"detail":"Internal Server Error"}'
log_message = 'Tenant alice_BHPCW - HTTP POST `/v1/connections/did-rotate/hangup` failed. Status code: 500. Response: `{"detail":"Internal Server Error"}`.'

    async def post(self, url: str, **kwargs) -> Response:
        try:
            response = await super().post(url, **kwargs)
            if self.raise_status_error:
                response.raise_for_status()  # Raise exception for 4xx and 5xx status codes
        except HTTPStatusError as e:
            code = e.response.status_code
            message = e.response.text
            log_message = f"{self.name} POST `{url}` failed. Status code: {code}. Response: `{message}`."
            logger.error(log_message)
    
>           raise HTTPException(status_code=code, detail=message) from e
E           fastapi.exceptions.HTTPException: 500: {"detail":"Internal Server Error"}

shared/util/rich_async_client.py:40: HTTPException