skip to Main Content

I’m following a tutorial trying to host Django on apache server, now as I finally installed mod_wsgi using cmd, I try to use the command:

mod_wsgi-express module-config

now i get another bugging error – which is:

  Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

(Adwy) C:UsersAdwy>mod_wsgi-express module-config
Traceback (most recent call last):
  File "C:UsersAdwyAppDataLocalProgramsPythonPython35Scriptsmod_wsgi-express-script.py", line 11, in <module>
    load_entry_point('mod-wsgi==4.5.20', 'console_scripts', 'mod_wsgi-express')()
  File "c:usersadwyappdatalocalprogramspythonpython35libsite-packagespkg_resources__init__.py", line 490, in load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File "c:usersadwyappdatalocalprogramspythonpython35libsite-packagespkg_resources__init__.py", line 2859, in load_entry_point
    return ep.load()
  File "c:usersadwyappdatalocalprogramspythonpython35libsite-packagespkg_resources__init__.py", line 2450, in load
    return self.resolve()
  File "c:usersadwyappdatalocalprogramspythonpython35libsite-packagespkg_resources__init__.py", line 2456, in resolve
    module = __import__(self.module_name, fromlist=['__name__'], level=0)
  File "c:usersadwyappdatalocalprogramspythonpython35libsite-packagesmod_wsgiserver__init__.py", line 24, in <module>
    from . import apxs_config
  File "c:usersadwyappdatalocalprogramspythonpython35libsite-packagesmod_wsgiserverapxs_config.py", line 27
    LIBEXECDIR = 'C:xamppapache/lib'
                    ^
SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes in position 2-4: truncated xXX escape


I’m looking for help!

thanks,

2

Answers


  1. Looks like you might need to set the MOD_WSGI_APACHE_ROOTDIR environment variable with forward slashes. example: “C:/foo/bar/apache”

    Take a look at this issue, which looks similar:
    https://github.com/GrahamDumpleton/mod_wsgi/issues/345

    Login or Signup to reply.
  2. Looks like you might need to set the MOD_WSGI_APACHE_ROOTDIR environment variable with forward slashes.
    example:

    "C:/foo/bar/apache"
    

    To apply this changes you need to reinstall mod_wsgi:

    pip uninstall mod_wsgi
    pip install mod_wsgi
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search