Tigris: boto3 delete policy failing?

>>> iam = boto3.client("iam", endpoint_url="https://fly.iam.storage.tigris.dev", region_name="auto")
>>> iam.delete_policy(PolicyArn='arn:aws:iam::...')
Traceback (most recent call last):
  File "<python-input-12>", line 1, in <module>
    iam.delete_policy(PolicyArn='arn:aws:iam::flyio_vogzmzedojomxp29:policy/test')
    ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.13/site-packages/botocore/client.py", line 569, in _api_call
    return self._make_api_call(operation_name, kwargs)
           ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.13/site-packages/botocore/client.py", line 1023, in _make_api_call
    raise error_class(parsed_response, operation_name)
botocore.exceptions.ClientError: An error occurred (NotImplemented) when calling the DeletePolicy operation: A header you provided implies functionality that is not implemented

From the debug log, the request headers appear to be:

Authorization: AWS4-HMAC-SHA256 Credential=..., SignedHeaders=content-type;host;x-amz-date, Signature=...
Content-Length: 108
Content-Type: application/x-www-form-urlencoded; charset=utf-8
User-Agent: Boto3/1.35.81 md/Botocore#1.35.81 ua/2.0 os/linux#6.11.9-amd64 md/arch#x86_64 lang/python#3.13.1 md/pyimpl#CPython cfg/retry-mode#legacy Botocore/1.35.81',
X-Amz-Date: 20241218T171536Z
amz-sdk-invocation-id: a80907a2-9c74-4e4e-8491-df6109508605
amz-sdk-request: attempt=1

Oh, I’m a derp. DeletePolicy is not on the list of implemented methods.

HI @AstraLuma - DeletePolicy is not yet implemented. As the workaround you can relax the policy and update it in place for now. It is in our backlog to implement it.

I guess by “update policy”, we mean “call CreatePolicy with the same name”.

Oh, and DeleteUserPolicy appears to be busted as well.

Yes create it with the same name. And DeleteUserPolicy was a doc error that is unsupported as of now. It is in backlog too.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.