Donate Share

TextIndexNG

Tracker: Bugs

5 Cannot set ranking option to False when defaulted to True - ID: 1580180
Last Update: Settings changed ( ajung )

It is not possible to unset the ranking option as a
parameter to the query when the default for the index
is True. I have found the origin of the problem,
however I am not sure where the fix should be applied.

The problem is that the get method of parseIndexRequest
will return the defaul argument even if the record has
the requested attribute, if the attribute value is
False. The _apply_index method of TextIndexNG uses the
get method to read the options, and so it is impossible
to turn ranking off.

I will fix this for my own needs by editing
_apply_index to use getattr directly on the record
object instead of using its get method. The behavior of
the parseIndexRequest get method seems rather
unconventional to me, but maybe there is a good reason
for it and I don't want to rick braking something else,
but I think desirable that the fix would occur there
instead.


Jean Lagarde ( lagj ) - 2006-10-19 03:16

5

Closed

Fixed

Andreas Jung

ZCatalogIntegration

TextIndexNG

Public


Comment ( 1 )

Date: 2006-11-25 14:19
Sender: ajungProject AdminAccepting Donations


Fixed for 3.2.0 and 3.1.14


Attached File

No Files Currently Attached

Changes ( 4 )

Field Old Value Date By
status_id Open 2006-11-25 14:19 ajung
resolution_id Accepted 2006-11-25 14:19 ajung
close_date - 2006-11-25 14:19 ajung
resolution_id None 2006-11-25 14:08 ajung