ServiceBusAdministrationClient
that forward_to
requires additional bearer token headers to be provided. We have fixed the bug in the PR:Azure/azure-sdk-for-python#15610. The fix will be carried in our next release.
I am using azure-storage-file-datalake package to connect with ADLS gen2
from azure.identity import ClientSecretCredential
# service principal credential
tenant_id = 'xxxxxxx'
client_id = 'xxxxxxxxx'
client_secret = 'xxxxxxxx'
storage_account_name = 'xxxxxxxx'
credential = ClientSecretCredential(tenant_id, client_id, client_secret)
service_client = DataLakeServiceClient(account_url="{}://{}.dfs.core.windows.net".format(
"https", storage_account_name), credential=credential) # I have also tried blob instead of dfs in account_url
Folder structure in ADLS gen2 from where I have to read parquet file look like this. Inside container of ADLS gen2 we folder_a which contain folder_b in which there is parquet file.
folder_a
|-folder_b
parquet_file1
from gen1 storage we used to read parquet file like this.
from azure.datalake.store import lib
from azure.datalake.store.core import AzureDLFileSystem
import pyarrow.parquet as pq
adls = lib.auth(tenant_id=directory_id,
client_id=app_id,
client_secret=app_key)
adl = AzureDLFileSystem(adls, store_name=adls_name)
f = adl.open(file, 'rb') # 'file is parquet file with path of parquet file folder_a/folder_b/parquet_file1'
table = pq.read_table(f)
How do we proceed with gen2 storage, we are stuck at this point
http://peter-hoffmann.com/2020/azure-data-lake-storage-gen-2-with-python.html is the link that we have followed.
Note - We are not using databrick to do this
Hi @qaiser21 , did you check the samples folder on the repo?
https://github.com/Azure/azure-sdk-for-python/tree/master/sdk/storage/azure-storage-file-datalake/samples
I don't have Storage representative that I can easily talk to Gitter, if we are missing a sample, could you create a bug on Github? https://github.com/Azure/azure-sdk-for-python/issues
Hi !
I would like to produce custom metric from python code
I dont find example or documentation for AZURE ( it's very easy for aws -> https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/publishingMetrics.html )
Could you help me find an exemple ?
thank you !!!!
Hi,
I'm trying to use AzureDatabricksLinkedService
from azure-mgmt-datafactory==1.0.0
package.
I've met two problems:
azure.core.exceptions.HttpResponseError: Operation returned an invalid status 'Bad Request'
It's hard to understand the exact problem via this error message.Any advisory on these issues would be really appreciated.
Error:
self._token = self._credential.get_token(*self._scopes)
AttributeError: 'AzureSasCredential' object has no attribute 'get_token'
Code:
credentials = AzureSasCredential(sas)
apim_client = ApiManagementClient(credential=credentials, subscription_id=subscription_id, base_url=base_url)
api_operation_operations = apim_client.api_operation.create_or_update(resource_group_name=resource_group_name, service_name=service_name,
api_id=api_id, operation_id=operation_id, parameters=operation_contract)
Hi Everyone,
I seems to be facing an issue with creating a managed_disk or snapshot from scratch disk of a VM, using begin_create_or_update
function and am getting the following error:
Error message was: Unable to build a model: Unable to deserialize to object: type, AttributeError: 'str' object has no attribute 'get', DeserializationError: Unable to deserialize to object: type, AttributeError: 'str' object has no attribute 'get'
I have seen a similar error to this earlier last year on this forum. Are they related or is this specific to each entity on Azure?
Thanks!!
Hey guys, I'm trying to start using the Entity Tag feature to ensure our transactions are properly isolated. I've been trying to use the documentation at https://azuresdkdocs.blob.core.windows.net/$web/python/azure-cosmos/4.0.0/azure.cosmos.html#azure.cosmos.container.ContainerProxy.replace_item and it defines an etag
keyword argument and a match_condition
argument. The match_condition
argument must apparently be present when the etag
argument is present, and takes an azure.core.MatchConditions
enum (an int from 1-5...).
Unfortunately, I can't find any documentation on what the various MatchConditions
options actually do...
There is a page that describes the enum (https://azuresdkdocs.blob.core.windows.net/$web/python/azure-core/1.1.1/azure.core.html#azure.core.MatchConditions) but it doesn't elaborate on what IfMissing
, IfModified
etc. actually mean.
To make matters murkier, I tried simply using the IfPresent
value just to see what would happen, and got a completely unexpected exception: TypeError("request() got an unexpected keyword argument 'etag'")
, which doesn't make any sense: why would the etag
be unexpected in this case?
Can anyone shed some light on this?
Hello.
I'm trying to get started with the azure.mgmt.logic
library. When I run the script I get ValueError: Invalid tenant id provided. You can locate your tenant id by following the instructions here: https://docs.microsoft.com/partner-center/find-ids-and-domain-names
. However, I am quite confident my tenant id is correct. I'm using it elsewhere and I've doublechecked no trailing spaces, etc. in the env var it's stored in. Any pointers?
I can't find any related issues on the web, so here it comes:
I try to make use of the Model.package() functionaity in the Azure ML Python SDK
It tries to connect to a file in a blob storage by making use of a SAS url, which is fine, but at the moment of requesting it, the sas is not valid yet, only when I call it manually later it does work...
so its an issue with timings, anyone who has an idea how to get this fixed?
you can try mgmt SDK to first check if the storage resource is there before connecting to it