Re: facet.sort does not work in python output

2007-05-09 Thread Yonik Seeley
On 5/3/07, Mike Klaas <[EMAIL PROTECTED]> wrote: On 5/3/07, Jack L <[EMAIL PROTECTED]> wrote: > The Python output uses nested dictionaries for facet counts. This might be fixed in the future It's fixed in the current development version (future 1.2), already. See http://wiki.apache.org/solr/So

Re: facet.sort does not work in python output

2007-05-03 Thread Erik Hatcher
We resort it in solr-ruby: def field_facets(field) facets = [] values = @data['facet_counts']['facet_fields'][field] Solr::Util.paired_array_each(values) do |key, value| facets << FacetValue.new(key, value) end facets end On May 3, 2007, at 8:10 PM, Mike Klaas wr

Re: facet.sort does not work in python output

2007-05-03 Thread Mike Klaas
On 5/3/07, Jack L <[EMAIL PROTECTED]> wrote: The Python output uses nested dictionaries for facet counts. I read it online that Python dictionaries do not preserve order. So when a string is eval()'d, the sorted order is lost in the generated Python object. Is it a good idea to use list to wrap a

Re: facet.sort does not work in python output

2007-05-03 Thread Jack L
The Python output uses nested dictionaries for facet counts. I read it online that Python dictionaries do not preserve order. So when a string is eval()'d, the sorted order is lost in the generated Python object. Is it a good idea to use list to wrap around the dictionary? This is only needed for t