Project

Profile

Help

Issue #2707

closed

pulp-manager command needs full path to wsgi in order to run from anywhere

Added by fdobrovo over 7 years ago. Updated almost 5 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Low
Assignee:
Category:
-
Sprint/Milestone:
Start date:
Due date:
Estimated time:
Severity:
1. Low
Version:
Platform Release:
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Easy Fix
Sprint:
Sprint 20
Quarter:

Description

(pulp) [vagrant@dev pulp]$ pulp-manager runserver 8080
Performing system checks...

System check identified no issues (1 silenced).
April 13, 2017 - 01:51:37
Django version 1.8.18, using settings 'pulp.app.settings'
Starting development server at http://127.0.0.1:8080/
Quit the server with CONTROL-C.
Unhandled exception in thread started by <function check_errors.<locals>.wrapper at 0x7fcaa0e59730>
Traceback (most recent call last):
  File "/usr/lib/python3.5/site-packages/Django-1.8.18-py3.5.egg/django/core/servers/basehttp.py", line 50, in get_internal_wsgi_application
    return import_string(app_path)
  File "/usr/lib/python3.5/site-packages/Django-1.8.18-py3.5.egg/django/utils/module_loading.py", line 26, in import_string
    module = import_module(module_path)
  File "/usr/lib64/python3.5/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 986, in _gcd_import
  File "<frozen importlib._bootstrap>", line 969, in _find_and_load
  File "<frozen importlib._bootstrap>", line 956, in _find_and_load_unlocked
ImportError: No module named 'wsgi'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3.5/site-packages/Django-1.8.18-py3.5.egg/django/utils/autoreload.py", line 229, in wrapper
    fn(*args, **kwargs)
  File "/usr/lib/python3.5/site-packages/Django-1.8.18-py3.5.egg/django/core/management/commands/runserver.py", line 141, in inner_run
    handler = self.get_handler(*args, **options)
  File "/usr/lib/python3.5/site-packages/Django-1.8.18-py3.5.egg/django/contrib/staticfiles/management/commands/runserver.py", line 24, in get_handler
    handler = super(Command, self).get_handler(*args, **options)
  File "/usr/lib/python3.5/site-packages/Django-1.8.18-py3.5.egg/django/core/management/commands/runserver.py", line 55, in get_handler
    return get_internal_wsgi_application()
  File "/usr/lib/python3.5/site-packages/Django-1.8.18-py3.5.egg/django/core/servers/basehttp.py", line 60, in get_internal_wsgi_application
    sys.exc_info()[2])
  File "/usr/lib/python3.5/site-packages/Django-1.8.18-py3.5.egg/django/utils/six.py", line 685, in reraise
    raise value.with_traceback(tb)
  File "/usr/lib/python3.5/site-packages/Django-1.8.18-py3.5.egg/django/core/servers/basehttp.py", line 50, in get_internal_wsgi_application
    return import_string(app_path)
  File "/usr/lib/python3.5/site-packages/Django-1.8.18-py3.5.egg/django/utils/module_loading.py", line 26, in import_string
    module = import_module(module_path)
  File "/usr/lib64/python3.5/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 986, in _gcd_import
  File "<frozen importlib._bootstrap>", line 969, in _find_and_load
  File "<frozen importlib._bootstrap>", line 956, in _find_and_load_unlocked
django.core.exceptions.ImproperlyConfigured: WSGI application 'wsgi.application' could not be loaded; Error importing module: 'No module named 'wsgi''
^CException ignored in: <function WeakValueDictionary.__init__.<locals>.remove at 0x7fcaa18f0730>
Traceback (most recent call last):
  File "/usr/lib64/python3.5/weakref.py", line 117, in remove
TypeError: 'NoneType' object is not callable
Exception ignored in: <function WeakValueDictionary.__init__.<locals>.remove at 0x7fcaa18f0730>
Traceback (most recent call last):
  File "/usr/lib64/python3.5/weakref.py", line 117, in remove
TypeError: 'NoneType' object is not callable

https://github.com/pulp/pulp/blob/bbcdb7c378d0784f0bf12a5e870b1eb06acb3ec1/app/pulp/app/settings.py#L106

needs to be changed to pulp.app.wsgi.application

Also available in: Atom PDF