-
Notifications
You must be signed in to change notification settings - Fork 130
Open
Description
I've just spent the last couple of hours being super confused by the following error message.
from rtree import index
points = (0.0, 0.0, 1.0, 1.0)
def gen():
for s, p in [('a', points)]:
yield s, p
index.Index(gen())RTreeError: Error in "Index_CreateWithStream": IllegalArgumentException: RTree::BulkLoader::bulkLoadUsingSTR: Empty data stream given.Improvement requests:
- Add the ability to use string indexes (useful for databases that use things like 00be976b-691b-4e1a-bcef-9336f13fb290 as keys), or
- Improve the error message so that it tells you you shouldn't be using string indexes.
Similarly, this error could also be improved:
idx = index.Index()
idx.insert('a', points)ArgumentError: argument 2: <class 'TypeError'>: wrong typeIssues:
- Should be TypeError
- It's the first argument
Something like
TypeError(f"Id values must be integers. Received {id=} with type {type(id}}")I'm open to implementing some of the things but I don't know C, only Python.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels