feat: expose table uri (#2922)

* Expose `table.uri` property for all tables, including remote tables
* Fix bug in path calculation on windows file systems
This commit is contained in:
Ryan Green
2026-01-20 19:56:46 -03:30
committed by GitHub
parent 4da01a0e65
commit cd5f91bb7d
8 changed files with 166 additions and 13 deletions

View File

@@ -1967,3 +1967,9 @@ def test_add_table_with_empty_embeddings(tmp_path):
on_bad_vectors="drop",
)
assert table.count_rows() == 1
def test_table_uri(tmp_path):
db = lancedb.connect(tmp_path)
table = db.create_table("my_table", data=[{"x": 0}])
assert table.uri == str(tmp_path / "my_table.lance")