#9990: Management shell autocomplete breaks PYTHONSTARTUP autocomplete --------------------------------------+------------------------------------- Reporter: bruno | Owner: nobody Status: new | Milestone: Component: Core framework | Version: SVN Keywords: management shell command | Stage: Unreviewed Has_patch: 1 | --------------------------------------+------------------------------------- * create a PYTHONSTARTUP file setting up autocompletion with readline * run manage.py shell * neither the PYTHONSTARTUP's autocomplete nor the shell command default's one work
(tested on ubuntu linux and gentoo linux with Python 2.5.x) The problem seems to come from the fact that the shell command install autocompletion _before_ executing the PYTHONSTARTUP. The attached patch reverse the order of operations, and check readline.get_completer before trying to install it's own completer. Worksforme, *but* requires that the PYTHONSTARTUP script pass globals() to the completer (else we'd be back to #5082). It also just ignore the use_plain flag except to tell wether to use IPython or the default shell(cf #5936). There's perhaps something better to do to get the whole thing right (perhaps passing a 'DJANGO_SHELL=1') option to execfile ???), but this is a design decision so I leave it to you guys. -- Ticket URL: <http://code.djangoproject.com/ticket/9990> Django <http://code.djangoproject.com/> The Web framework for perfectionists with deadlines. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django updates" group. To post to this group, send email to django-updates@googlegroups.com To unsubscribe from this group, send email to django-updates+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-updates?hl=en -~----------~----~----~----~------~----~------~--~---