mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
64dbf8c1e3
* [FR] Add tracing support Fixes #6208 * move checks out of manage.py * fixed reqs * small cleanup * move tracing init to settings similar to how sentry is handled * rephrase * clean up imports * added argument regarding console debugging * fix typing * added auth section * remove empty headers * made protocol configurable * rename vars & cleanup template * more docs for template * add docs
25 lines
671 B
Python
Executable File
25 lines
671 B
Python
Executable File
#!/usr/bin/env python
|
|
"""InvenTree / django management commands."""
|
|
|
|
import os
|
|
import sys
|
|
|
|
|
|
def main():
|
|
"""Run administrative tasks."""
|
|
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'InvenTree.settings')
|
|
|
|
try:
|
|
from django.core.management import execute_from_command_line
|
|
except ImportError as exc: # pragma: no cover
|
|
raise ImportError(
|
|
"Couldn't import Django. Are you sure it's installed and "
|
|
'available on your PYTHONPATH environment variable? Did you '
|
|
'forget to activate a virtual environment?'
|
|
) from exc
|
|
execute_from_command_line(sys.argv)
|
|
|
|
|
|
if __name__ == '__main__':
|
|
main()
|