lancedb: bug(python): table can't be opened in azure storage
LanceDB version
v0.6.2
What happened?
Followed the instructions here to connect to azure blob storage. I set the required environment variables and connected to the database. I was able to see the correct tables using db.table_names() so I know the connection was successful.
When I tried db.open_table for the listed tables I got the following error:
ArrowInvalid Traceback (most recent call last)
File <command-18817827359282>, line 1
----> 1 all_table = db.open_table("all_content")
File /local_disk0/.ephemeral_nfs/envs/pythonEnv-7201c84b-5d15-4c4f-b92d-1e96b0358490/lib/python3.10/site-packages/lancedb/db.py:417, in LanceDBConnection.open_table(self, name)
404 @override
405 def open_table(self, name: str) -> LanceTable:
406 """Open a table in the database.
407
408 Parameters
(...)
415 A LanceTable object representing the table.
416 """
--> 417 return LanceTable.open(self, name)
File /local_disk0/.ephemeral_nfs/envs/pythonEnv-7201c84b-5d15-4c4f-b92d-1e96b0358490/lib/python3.10/site-packages/lancedb/table.py:838, in LanceTable.open(cls, db, name, **kwargs)
835 @classmethod
836 def open(cls, db, name, **kwargs):
837 tbl = cls(db, name, **kwargs)
--> 838 fs, path = fs_from_uri(tbl._dataset_uri)
839 file_info = fs.get_file_info(path)
840 if file_info.type != pa.fs.FileType.Directory:
File /local_disk0/.ephemeral_nfs/envs/pythonEnv-7201c84b-5d15-4c4f-b92d-1e96b0358490/lib/python3.10/site-packages/lancedb/util.py:95, in fs_from_uri(uri)
92 path = get_uri_location(uri)
93 return fs, path
---> 95 return pa_fs.FileSystem.from_uri(uri)
File /local_disk0/.ephemeral_nfs/envs/pythonEnv-7201c84b-5d15-4c4f-b92d-1e96b0358490/lib/python3.10/site-packages/pyarrow/_fs.pyx:471, in pyarrow._fs.FileSystem.from_uri()
File /local_disk0/.ephemeral_nfs/envs/pythonEnv-7201c84b-5d15-4c4f-b92d-1e96b0358490/lib/python3.10/site-packages/pyarrow/error.pxi:154, in pyarrow.lib.pyarrow_internal_check_status()
File /local_disk0/.ephemeral_nfs/envs/pythonEnv-7201c84b-5d15-4c4f-b92d-1e96b0358490/lib/python3.10/site-packages/pyarrow/error.pxi:91, in pyarrow.lib.check_status()
pyarrow == 15.0.0 is installed.
Are there known steps to reproduce?
No response
About this issue
- Original URL
- State: open
- Created 3 years ago
- Reactions: 3
- Comments: 16 (5 by maintainers)
Commits related to this issue
- fix(python): Add python azure blob read support (#1102) I know there's a larger effort to have the python client based on the core rust implementation, but in the meantime there have been several i... — committed to lancedb/lancedb by rcdilorenzo 3 years ago
- fix(python): Add python azure blob read support (#1102) I know there's a larger effort to have the python client based on the core rust implementation, but in the meantime there have been several i... — committed to raghavdixit99/lancedb by rcdilorenzo 3 years ago
- fix(python): Add python azure blob read support (#1102) I know there's a larger effort to have the python client based on the core rust implementation, but in the meantime there have been several i... — committed to raghavdixit99/lancedb by rcdilorenzo 3 years ago
- fix(python): Add python azure blob read support (#1102) I know there's a larger effort to have the python client based on the core rust implementation, but in the meantime there have been several i... — committed to lancedb/lancedb by rcdilorenzo 3 years ago
Looks like this is also noted in #485. @westonpace, were any of the read commands ever working for azure? I see that logic for reading in lancedb-python has special logic for S3 and pyarrow.fs doesn’t support azure. I’ve got a concrete use case for a product of ours that I’m performance testing before we use this but the azure support for reading is a blocker. If the support is there soon, we’d love to use this in production ASAP. 🤩
Haven’t worked on this yet, but I expect to get to work on it before the end of the year.
Same here. I’m testing LanceDB in dev by accessing it from a volume in Databricks to load data (which requires a full copy/overwrite of the lance files each time) and mounting the container in an Azure Web App so that langchain can access lance from the “local” filesystem. Problem is I’m seeing massive latency on reads for both cases.
In Databricks when reading from a lance table that is stored in a volume (adls gen2 standard) I’m seeing 2-3 minutes of latency per search. In the Web App I’m getting p95 latency of around 12 seconds. Obviously neither of these will work in production. When I move the table to the local filesystem the latency drops to sub-100ms range that I expect from an unindexed table.
This is all to say that I was hoping to use the
az://filesystem to get around these latency issues so I’m really hoping it’s fixed soon if possible!