Opened 14 years ago

Closed 14 years ago

#15159 closed (wontfix)

createsuperuser can't be interrupted or suspended

Reported by: Paul Winkler Owned by: nobody
Component: Core (Management commands) Version: 1.2
Severity: Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

To reproduce:

  • django-admin.py createsuperuser
  • enter an email address
  • at the password prompt, change your mind and hit Ctrl-C
  • that doesn't work, try Ctrl-Z
  • that doesn't work either, you just keep getting prompted

Workaround is to kill from another terminal or ssh session.

Change History (5)

comment:1 by John Anderson, 14 years ago

You can use Ctrl+d to interrupt this prompt. Ctrl+d sends EOF. This is the only way to interrupt it since the special way getpass has to modify the terminal to disable echo. This isn't a bug.

comment:2 by Russell Keith-Magee, 14 years ago

Triage Stage: UnreviewedAccepted

It's is a bug; a command line tools should obey SIGINT.

comment:3 by mmcnickle, 14 years ago

If it's a bug, it's an upstream python bug. The python UNIX implementation of getpass() seems to actively suppress SIGINTs http://svn.python.org/view/python/trunk/Lib/getpass.py?revision=76000&view=markup#l65 though the windows implementation seems to allow it http://svn.python.org/view/python/trunk/Lib/getpass.py?revision=76000&view=markup#l101

comment:4 by mmcnickle, 14 years ago

There is a very recent upstream bug report for this: http://bugs.python.org/issue11236

comment:5 by Russell Keith-Magee, 14 years ago

Resolution: wontfix
Status: newclosed

Given that this is an upstream bug, and fixing it will be a non-trivial task, I'm going to mark this wontfix.

Of course, if someone finds a trivial workaround, feel free to reopen and provide that patch.

Note: See TracTickets for help on using tickets.
Back to Top