On Tue, 2009-02-17 at 15:34 -0800, Yanik wrote: > I've been having this problem for a few weeks and I can't, for the > life of me, figure it out. > > I have 2 types of environments: my local dev server, running Ubuntu, > and the live server, running Fedora 9. The problem only occurs on on > the Fedora server and only when Debug = False. The tricky par is, only > this line crash, but not all the time. And hitting refresh 2-3 times > will eventually go through. > > > return super(ActiveManager, self).get_query_set().filter > (is_active=True) > > will give me the error "TypeError: super() argument 1 must be type, > not None"
You don't tell us much about your code, but grepping through the Django source shows that we don't have anything called ActiveManager, so I'm assuming this is something your wrote. When is the above line of code being executed? At something like import time (which might result in a non-constructed object problem)? Can you reduce the problem to a really tiny example? Try making a project that contains only the file with that line and its dependencies. Then remove the dependencies that are elsewhere in the file (by removing the code elsewhere in the file). Hopefully you'll reduce it to something that fails with some regularity and is only a couple of dozen of lines long. Based on your description, I strongly suspect an import problem (circular imports or executing code at import time, for example). For a couple of reasons: it only happens for some threads of execution (refreshing a few times will hit other Apache processes -- ditto for other webservers), the None reported suggests an incomplete object construction (it's a weird error and I can't imagine how you could cause it happen randomly outside of import-time and __new__ execution cases). > > > It seemed like a caching problem, How did you establish that? I don't see any evidence to support that guess from what you've posted. Malcolm --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---