title: How do I fix my url patterns for django 1.10.2?
body: <p>This is my url pattern:</p>
  
  <pre><code>from django.conf.urls import url
  from django.contrib import admin
  from school.views import home
  
  urlpatterns = [
      url(r'^admin/', admin.site.urls),
      #url(r'^$', home, name = 'home') #school.views.home')
  
      #url(r'^$', 'main.views.home', name = 'school_home')
      url(r'^$', home, name = 'home')
  ]
  
  urlpatterns = [
      #'django.contrib.auth.views',
  
      url(r'^login/$', 'login', {'template_name': 'login.html'}, name = 'school_login'),
  
      url(r'^logout/$', 'logout', {'next_page': 'school_home'},  name = 'school_logout'),
      ]
  </code></pre>
  
  <p>For some reason I keep getting these awful errors that just won't let my application run when I ask it to runserver.</p>
  
  <p>Here is my traceback error message:</p>
  
  <pre><code>Unhandled exception in thread started by &lt;function check_errors.&lt;locals&gt;.wrapper
   at 0x03F292B8&gt;
  Traceback (most recent call last):
    File "C:\Python34\lib\site-packages\django\utils\autoreload.py", line 226, in
  wrapper
      fn(*args, **kwargs)
    File "C:\Python34\lib\site-packages\django\core\management\commands\runserver.
  py", line 121, in inner_run
      self.check(display_num_errors=True)
    File "C:\Python34\lib\site-packages\django\core\management\base.py", line 374,
   in check
      include_deployment_checks=include_deployment_checks,
    File "C:\Python34\lib\site-packages\django\core\management\base.py", line 361,
   in _run_checks
      return checks.run_checks(**kwargs)
    File "C:\Python34\lib\site-packages\django\core\checks\registry.py", line 81,
  in run_checks
      new_errors = check(app_configs=app_configs)
    File "C:\Python34\lib\site-packages\django\core\checks\urls.py", line 14, in c
  heck_url_config
      return check_resolver(resolver)
    File "C:\Python34\lib\site-packages\django\core\checks\urls.py", line 24, in c
  heck_resolver
      for pattern in resolver.url_patterns:
    File "C:\Python34\lib\site-packages\django\utils\functional.py", line 35, in _
  _get__
      res = instance.__dict__[self.name] = self.func(instance)
    File "C:\Python34\lib\site-packages\django\urls\resolvers.py", line 313, in ur
  l_patterns
      patterns = getattr(self.urlconf_module, "urlpatterns", self.urlconf_module)
    File "C:\Python34\lib\site-packages\django\utils\functional.py", line 35, in _
  _get__
      res = instance.__dict__[self.name] = self.func(instance)
    File "C:\Python34\lib\site-packages\django\urls\resolvers.py", line 306, in ur
  lconf_module
      return import_module(self.urlconf_name)
    File "C:\Python34\lib\importlib\__init__.py", line 109, in import_module
      return _bootstrap._gcd_import(name[level:], package, level)
    File "&lt;frozen importlib._bootstrap&gt;", line 2254, in _gcd_import
    File "&lt;frozen importlib._bootstrap&gt;", line 2237, in _find_and_load
    File "&lt;frozen importlib._bootstrap&gt;", line 2226, in _find_and_load_unlocked
    File "&lt;frozen importlib._bootstrap&gt;", line 1200, in _load_unlocked
    File "&lt;frozen importlib._bootstrap&gt;", line 1129, in _exec
    File "&lt;frozen importlib._bootstrap&gt;", line 1471, in exec_module
    File "&lt;frozen importlib._bootstrap&gt;", line 321, in _call_with_frames_removed
    File "C:\Python34\Scripts\schoolDatabase\schoolDatabase\urls.py", line 31, in
  &lt;module&gt;
      url(r'^login/$', 'login', {'template_name': 'login.html'}, name = 'school_lo
  gin'),
    File "C:\Python34\lib\site-packages\django\conf\urls\__init__.py", line 85, in
   url
      raise TypeError('view must be a callable or a list/tuple in the case of incl
  ude().')
  TypeError: view must be a callable or a list/tuple in the case of include().
  </code></pre>
  
  <p>I've had a look at other stackoverflow questions regarding the url pattern and I've tried adjusting it but it still won't work. </p>
  
  <p>Can anybody help?</p>