Ticket #13062: copy_warnoptions.diff

File copy_warnoptions.diff, 512 bytes (added by Claude Paroz, 14 years ago)

Copy warnoptions before spawning child

  • django/utils/autoreload.py

    diff --git a/django/utils/autoreload.py b/django/utils/autoreload.py
    index 8d9d6f2..51aaccd 100644
    a b def reloader_thread():  
    7575
    7676def restart_with_reloader():
    7777    while True:
    78         args = [sys.executable] + sys.argv
     78        args = [sys.executable] + ['-W%s' % o for o in sys.warnoptions] + sys.argv
    7979        if sys.platform == "win32":
    8080            args = ['"%s"' % arg for arg in args]
    8181        new_environ = os.environ.copy()
Back to Top