`zope.index.text.TextIndex` sometimes uses the wrong lexicon
Bug #232516 reported by
Alex Smith
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Zope 3 |
Won't Fix
|
Undecided
|
Unassigned | ||
zope.index |
Fix Released
|
Undecided
|
Tres Seaver |
Bug Description
`zope.index.
At a minimum, `TextIndex` should raise an exception when constructed with an index but no lexicon. Ideally, `TextIndex` would be able to use the lexicon from the provided index itself, but currently there is no specified way to get a lexicon from an index.
Related branches
lp:~tseaver/zope.index/lp232516
(Merged)
Changed in zope3: | |
status: | New → Won't Fix |
Changed in zope.index: | |
assignee: | nobody → Tres Seaver (tseaver) |
status: | New → In Progress |
To post a comment you must log in.
It is unfortunate that the constructor for the `TextIndex` class isn't
documented except by the code; the tests cover only the case for
passing no arguments.
As long as there's no API to get a lexicon from the underlying index
that was passed in, the constructor should raise an exception when
passed an index but no lexicon. `ValueError` would be appropriate in
this case.