Skip to content

Poor error message for unsupported operations #13128

@chlowell

Description

@chlowell

CertificateClient supports Key Vault version 2016-10-01, but that service version doesn't support the backup_certificate operation added in 7.0. So this code raises an error:

from azure.keyvault.certificates import ApiVersion, CertificateClient

client = CertificateClient(VAULT_URL, object(), api_version=ApiVersion.V2016_10_01)
client.backup_certificate("...")

The error suggests the client or service doesn't support this particular API version, when in fact it's only this particular operation which is not supported:

  File "...\azure-keyvault-certificates\azure\keyvault\certificates\_generated\_operations_mixin.py", line 54, in backup_certificate
    raise NotImplementedError("APIVersion {} is not available".format(api_version))
NotImplementedError: APIVersion 2016-10-01 is not available

Metadata

Metadata

Assignees

No one assigned

    Labels

    Autorest IssueClientThis issue points to a problem in the data-plane of the library.KeyVault

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions