HungYangChang commented on issue #1588:
URL:
https://github.com/apache/iceberg-python/issues/1588#issuecomment-2637506077
Hi @kevinjqliu
Thanks for the hint
I still have some issues set up the fileio for ADLS gen2 storage
This is my script:
```
STORAGE_ACCOUNT = "xuievents"
CONTAINER_NAME = "lakekeeper-test-storage"
credential = ClientSecretCredential(
tenant_id=AZURE_TENANT_ID,
client_id=AZURE_CLIENT_ID,
client_secret=AZURE_CLIENT_SECRET
)
# solution 1
# error: TypeError: FsspecFileIO.__init__() got an unexpected keyword
argument 'fs'
fs_adl = fsspec.filesystem(
"abfs",
account_name=STORAGE_ACCOUNT,
credential=credential,
)
file_io = FsspecFileIO(fs=fs_adl)
# solution 2
# error: Must provide either a connection_string or account_name with
credentials!!
file_io = FsspecFileIO(properties={"account_name": STORAGE_ACCOUNT,
"credential": credential})
# soultion 3
# error: Must provide either a connection_string or account_name with
credentials!!
file_io =
FsspecFileIO("abfs://[email protected]/")
CATALOG_URL = "http://localhost:8181/catalog"
WAREHOUSE_PATH = "test"
catalog = RestCatalog(
name="test_catalog",
uri=CATALOG_URL,
warehouse=WAREHOUSE_PATH,
token="dummy",
properties={
"azure.account-name": STORAGE_ACCOUNT,
"azure.container": CONTAINER_NAME,
"azure.endpoint": "https://xuievents.dfs.core.windows.net",
"azure.client-id": AZURE_CLIENT_ID,
"azure.tenant-id": AZURE_TENANT_ID,
"azure.client-secret": AZURE_CLIENT_SECRET,
"io-impl": "pyiceberg.io.fsspec.FsspecFileIO",
}
)
catalog.file_io = file_io
```
Thanks for your answer in advance
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]