All fixed - anyone who stumbles across this error - update to the
latest trunk of django-sphinx and works fine!

On Jan 20, 1:23 pm, Alfonso <allanhender...@gmail.com> wrote:
> Hello,
>
> I've used django-sphinx/sphinx engine in the past and found it a
> fantasic solution but now running into a problem in a new build I
> haven't seen before:
>
> So sphinx is all set up and working and in the appropriate view I
> have:
>
> def search(request):
>         search_query = request.GET.get('q','')
>         if search_query:
>                 queryset1 = Books.search.query(search_query)
>                 results1 = queryset1.order_by(@id)
>         else:
>                 results1 = []
>         return render_to_response("search.html", {"results1": results1,
> "query": search_query })
>
> Which should work... in the template I have a very simple block:
>
>   {% if query %}
>     <h1>Your results for "{{ query|escape }}":</h1>
>     {% if results1 %}
>       {% for result in results1 %}
>                 <dl>
>                                 <dd>{{ result.name }}</dd>
>                 </dl>
>       {% endfor %}
>       {% else %}
>           <h3>No Results</h3>
>                         {% endif %}
>                 {% endif %}
>
> But that's where I'm getting the following error:
>
> TemplateSyntaxError at /search/
> Caught an exception while rendering: maximum recursion depth exceeded
> in cmp
>
> It happens when I do a generic query with 1000 results returned or
> specific yielding just 1 result.
>
> Anyone got any idea where the problem might lie?  Interestingly if I
> just send the result count to the template it is displayed just fine
> with {{ result1 }}.
>
> Thanks!
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to