Opened 19 years ago
Closed 19 years ago
#2036 closed defect (fixed)
utils/autoreload.py falls over when "thread" module is not installed
| Reported by: | Owned by: | Adrian Holovaty | |
|---|---|---|---|
| Component: | Core (Management commands) | Version: | |
| Severity: | normal | Keywords: | |
| Cc: | Triage Stage: | Unreviewed | |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description
Python's thread module is the interface to your systems pthreads library - and it's also an optional module, as not all systems support pthreads. Where pthreads are not available, the "dummy_thread" module can be used as a drop-in replacement..
easy to do..instead of:
import os, sys, thread, time
use:
import os, sys, time
try:
import thread
except:
import dummy_thread as thread
Note:
See TracTickets
for help on using tickets.
(In [3020]) Fixed #2036 -- autoreload.py no longer fails for uninstalled 'thread' module. Thanks, plmeister@…