Re: QuerySet not iterable

2019-10-10 Thread Abhijeet Viswa
Hey there guys, I'm happy to say that we've finally figured out the bug. It was never an error with the underlying DBMS or Django itself. It was our code. It's sad that we didn't figure it out sooner and had to spend so many man hours on this. As I said, the *select_for_update *was never a pr

Re: QuerySet not iterable

2019-10-08 Thread Abhijeet Viswa
Hello, Thank your for your reply. I'm not using Python 2. I have attached the traceback as is emailed by Django to the Admin. Traceback: > > File > "/home/user/api/env/lib/python3.6/site-packages/django/core/handlers/exception.py" > > in inner > 34. response = get_response(req

Re: QuerySet not iterable

2019-10-08 Thread Simon Charette
Hello there, >From looking at your code (super() calls) it seems like your are using Python 2. We've seen similar reports about stdlib functions hiding system level exceptions instead of surfacing them[0] so that might it. It's hard to tell without the full traceback though. Best, Simon [0]

QuerySet not iterable

2019-10-07 Thread Abhijeet Viswa
Hey guys, I need a help with a quirky bug while iterating over a QuerySet: > TypeError: argument of type 'QuerySet' is not iterable The following is the block of code that produces the error: (the save method overrides the default save method in a Model called *Transaction*) def save(self, *