Skip to content

Inconsistent behaviour when blob contains .. in path #38992

Open
@lejmr

Description

@lejmr
  • azure-storage-file-datalake:
  • 12.17.0:
  • MacOs 15:
  • 3.11:

Describe the bug

When placing .. into the path, I get blob properties, can create files, etc., just fine, but I cannot list the directory.

To Reproduce

account_name = "REDACTED"
account_url_dfs = f"https://{account_name}.dfs.core.windows.net"
container_name = "tmp"
blob ='test/../test/test2/'

credential = get_azure_credential()
fsc = DataLakeServiceClient(account_url=account_url_dfs, credential=credential).get_file_system_client(container_name)
properties = fsc.get_file_client(blob).get_file_properties()
fsc.create_file(f"{blob}file.txt")

# This line fails with `azure.core.exceptions.ResourceNotFoundError: The specified path does not exist.` 
paths = list(fsc.get_paths(blob))

Expected behavior
I am expecting to get list of files or directories from given directory

Metadata

Metadata

Labels

ClientThis issue points to a problem in the data-plane of the library.Service AttentionWorkflow: This issue is responsible by Azure service team.StorageStorage Service (Queues, Blobs, Files)customer-reportedIssues that are reported by GitHub users external to the Azure organization.feature-requestThis issue requires a new behavior in the product in order be resolved.needs-team-attentionWorkflow: This issue needs attention from Azure service team or SDK team

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions