Registry / azure / azure-mgmt-hanaonazure

azure-mgmt-hanaonazure

JSON →
library1.0.1pypypi✓ verified 22d ago

The `azure-mgmt-hanaonazure` library is the Microsoft Azure SAP Hana on Azure Management Client Library for Python. Its current stable version is 1.0.0, released in April 2021. This library is part of the older generation of Azure SDKs and has been officially deprecated, with support for the underlying older SDK guidelines ending. Developers are advised to migrate to the newer Azure SDK management libraries for continued support and updates.

pip install azure-mgmt-hanaonazure azure-identity
INSTALL
IMPORT
SIG · AZURE-MGMT-HANAONA
A
azure-mgmt-hanaonazure
azurepythonv1.0.1
Install
3.7s avg
Import
545ms
Disk
42MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v1.0.1 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 0.584s · 43.6MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 3.7s · import 0.506s · 44MB
42MB installed
● package 42MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

HanaManagementClient
from azure.mgmt.hanaonazure import HanaManagementClient
from azure.mgmt.hanaonazure.hana_management_client import HanaManagementClient
As of v1.0.0, the client cannot be imported from the sub-module; import directly from the package root.
DefaultAzureCredential
from azure.identity import DefaultAzureCredential

This quickstart demonstrates how to authenticate with Azure using `DefaultAzureCredential` and initialize the `HanaManagementClient`. It then attempts to list available operations, which is a common pattern for Azure management clients to verify connectivity and access.

import os from azure.identity import DefaultAzureCredential from azure.mgmt.hanaonazure import HanaManagementClient # Set your Azure Subscription ID as an environment variable or replace directly SUBSCRIPTION_ID = os.environ.get("AZURE_SUBSCRIPTION_ID", "your-subscription-id") if SUBSCRIPTION_ID == "your-subscription-id": print("Please set the AZURE_SUBSCRIPTION_ID environment variable or replace 'your-subscription-id'.") exit(1) # Authenticate with Azure. DefaultAzureCredential attempts several common authentication methods. credential = DefaultAzureCredential() # Create a client for SAP Hana on Azure Management client = HanaManagementClient(credential, SUBSCRIPTION_ID) print(f"Listing SAP HANA on Azure operations for subscription: {SUBSCRIPTION_ID}") # Example: List available operations (a common pattern for management clients) # Note: Specific resource listing methods may vary, this is a generic example. # If there are no specific 'list' methods on the client root, one might need to access # sub-clients like client.operations.list() or client.hana_instances.list() try: # Assuming there's a list method for operations or a top-level resource. # The exact method will depend on the API definition for HanaOnAzure. # For demonstration, we'll try a common pattern. If it fails, actual usage # requires consulting the specific service's API reference. # As per docs, 'operations' is a common attribute for listing supported ops. for operation in client.operations.list(): print(f"Operation: {operation.name} - {operation.display.provider}/{operation.display.resource}/{operation.display.operation}") except AttributeError: print("Client does not have a 'operations.list()' method. Please consult the API reference for available resource management methods, e.g., for listing HANA instances.") except Exception as e: print(f"An error occurred: {e}")
Debug
Known issues
breakingThis library (`azure-mgmt-hanaonazure`) is officially deprecated. Microsoft recommends migrating to newer Azure SDK management libraries for ongoing support, security updates, and new features.
fix
Migrate to the equivalent service in the latest Azure SDK for Python. Consult Azure SDK documentation for the replacement package (e.g., `azure-resourcemanager` for Java, implying a similar shift for Python).
affects: All versions, as it's part of an older SDK generation.
breakingThe credential system was completely revamped. `azure.common.credentials` or `msrestazure.azure_active_directory` instances are no longer supported. Use `azure-identity` classes (e.g., `DefaultAzureCredential`). The `credentials` parameter has been renamed to `credential`.
fix
Replace old credential classes with `azure-identity` (e.g., `DefaultAzureCredential`) and ensure the client constructor uses the `credential` parameter.
affects: 1.0.0b1 and later (stable 1.0.0 is affected).
breakingOperations that previously returned `msrest.polling.LROPoller` now return `azure.core.polling.LROPoller` and are prefixed with `begin_` (e.g., `create_or_update` becomes `begin_create_or_update`).
fix
Update method calls to use the `begin_` prefix for long-running operations and expect `azure.core.polling.LROPoller` for polling results.
affects: 1.0.0b1 and later (stable 1.0.0 is affected).
breakingThe `HanaManagementClient` class cannot be imported from `azure.mgmt.hanaonazure.hana_management_client`. It must be imported directly from the package root: `from azure.mgmt.hanaonazure import HanaManagementClient`.
fix
Adjust import statements to import `HanaManagementClient` directly from `azure.mgmt.hanaonazure`.
affects: 1.0.0b1 and later (stable 1.0.0 is affected).
breakingThe `config` attribute no longer exists on client objects. Configuration should be passed as keyword arguments during client instantiation (e.g., `MyClient(credential, subscription_id, enable_logging=True)`).
fix
Pass client configuration settings as keyword arguments during the client's `__init__` call, referring to `azure-core` documentation for supported options.
affects: 1.0.0b1 and later (stable 1.0.0 is affected).
breakingThe exception hierarchy has been simplified. Most exceptions are now `azure.core.exceptions.HttpResponseError`. `CloudError` has been removed.
fix
Update exception handling blocks to catch `azure.core.exceptions.HttpResponseError` instead of `CloudError` or other older, specific exceptions.
affects: 1.0.0b1 and later (stable 1.0.0 is affected).
gotchaThe `azure-mgmt-hanaonazure` package was explicitly tested only up to Python 3.8. Using it with newer Python versions (e.g., 3.9+) might encounter unexpected compatibility issues, although it may still function.
fix
For new projects, use the recommended newer Azure SDKs. For existing projects, consider testing thoroughly with newer Python versions or sticking to Python 3.8 or older for this specific library.
affects: Python 3.9 and newer when using this library.
Upgrade
Version history
1.0.1latest on PyPI · released May 18, 2026
Audit
Dependencies
azure-identityrequiredRequired for modern Azure Active Directory token authentication with DefaultAzureCredential.
azure-corerequiredProvides core functionalities like HTTP pipeline, error handling, and polling, typically a transitive dependency.
Agent activity
47 hits · last 30 days
node
40
OpenAI (training)
1
Resources