summaryrefslogtreecommitdiff
path: root/tests/utils_tests/test_module/__main__.py
AgeCommit message (Collapse)Author
2021-01-05Fixed #32314 -- Fixed detection when started non-django modules with "python ↵William Schwartz
-m" in autoreloader. django.utils.autoreload.get_child_arguments() detected when Python was started with the `-m` option only for `django` module. This commit changes the logic to check __spec__, see https://docs.python.org/3/reference/import.html#main-spec Now packages can implement their own __main__ with the runserver command.