I have looked at my system and found that I has installed also Python-2.4.4 and IPython. I have firstly uninstalled Python-2.4.4 and tried once more the same command "python manage.py shell'' in project directory. I have got the same problem. Then I have uninstalled the IPython also, and the problem is solved! If I do "python manage.py shell'' I get :
Python 2.5.1 (r251:54863, Oct 26 2007, 01:35:31) [GCC 4.1.2 (Gentoo 4.1.2)] on linux2 Type "help", "copyright", "credits" or "license" for more information. (InteractiveConsole) >>> It is Ok! I don't understand what the problem was. Thank for the giving some indication! On Nov 20, 9:26 pm, "Marty Alchin" <[EMAIL PROTECTED]> wrote: > Well, all that tells me is that you're running Python 2.5, which i > already knew from the nature of your error message. > > Allow me to rephrase. The message you saw *is expected* under Python > 2.5. The code you listed probably worked before, but it *will not > work* in Python 2.5 or future versions of Python. > > So the real issue is this: why are you trying to modify > __builtin__.exit? It's not allowed, so you'll need to find another way > to do whatever it is you're trying to do. > > Perhaps some more code could explain what you're trying to do, and how > best to get around it. > > -Gul > > On Nov 20, 2007 3:17 PM, Nader <[EMAIL PROTECTED]> wrote: > > > > > It is a Linux machine with a Gentoo and Python in this is: > > > #pyhton > > Python 2.5.1 (r251:54863, Oct 26 2007, 01:35:31) > > [GCC 4.1.2 (Gentoo 4.1.2)] on linux2 > > Type "help", "copyright", "credits" or "license" for more information. > > > On Nov 20, 9:01 pm, "Marty Alchin" <[EMAIL PROTECTED]> wrote: > > > > On Nov 20, 2007 2:22 PM, Nader <[EMAIL PROTECTED]> wrote: > > > > > If I use the "python manage.py shell" to go to shell, I got the next > > > > message: > > > > > _builtin__.exit += _exit > > > > TypeError: unsupported operand type(s) for +=: 'Quitter' and 'str' > > > > > It is actually part of error. > > > > Some idea what the problem is? > > > > I'm not sure what exactly you're trying to do here, but I'll hazard a > > > guess as to what the "problem" is. Prior to Python 2.5, > > > __builtin__.exit was a string containing something like "Use Ctrl-Z > > > plus Return to exit." (on Windows anyway). In Python 2.5, > > > __built__.exit is a class, which exits the interpreter, when called. > > > So the following line was invalid under Python 2.4, but became > > > possible with Python 2.5. > > > > >>> exit() > > > > It looks like you're relying on __builtin__.exit being a string, which > > > is no longer the case if you recently upgraded to Python 2.5. > > > > -Gul --~--~---------~--~----~------------~-------~--~----~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---