Django Rendering Error for Template
<p><strong>Issue:</strong></p>

<p>When running <code>django startproject manage.py</code></p>

<p>I receive the following error despite paths being correct when I print them to terminal:</p>

<pre><code>    Traceback (most recent call last):
  File "pathdjango\core\handlers\exception.py", line 39, in inner
    response = get_response(request)
  File "pathdjango\core\handlers\base.py", line 187, in _get_response
    response = self.process_exception_by_middleware(e, request)
  File "pathdjango\core\handlers\base.py", line 185, in _get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "fullpathprojects\demo\csdemo\csdemo\views.py", line 6, in index
    return render(request,'templates/index.html')
  File "pathdjango\shortcuts.py", line 30, in render
    content = loader.render_to_string(template_name, context, request, using=using)
  File "pathdjango\template\loader.py", line 67, in render_to_string
    template = get_template(template_name, using=using)
  File "pathdjango\template\loader.py", line 21, in get_template
    return engine.get_template(template_name)
  File "pathdjango\template\backends\django.py", line 39, in get_template
    return Template(self.engine.get_template(template_name), self)
  File "pathdjango\template\engine.py", line 160, in get_template
    template, origin = self.find_template(template_name)
  File "pathdjango\template\engine.py", line 134, in find_template
    name, template_dirs=dirs, skip=skip,
  File "pathdjango\template\loaders\base.py", line 38, in get_template
    contents = self.get_contents(origin)
  File "pathdjango\template\loaders\filesystem.py", line 24, in get_contents
    with io.open(origin.name, encoding=self.engine.file_charset) as fp:
IOError: [Errno 22] Invalid argument: u'fullpath\\demo\\csdemo\\:\\templates\\index.html'
</code></pre>

<p>I'm not sure why there is a ':' in the middle of the path.</p>

<p>I'm following this tutorial for reference <a href="https://www.youtube.com/watch?v=KiGE2KpiwtA&amp;index=4&amp;list=PLSBpJCyDA8W4x-1Bwc9nYZBxEiq6Z8uzw&amp;t=1369s" rel="nofollow noreferrer">here:</a></p>

<p><strong>What works:</strong></p>

<p>I can view admin.</p>

<p><strong>Background:</strong></p>

<p>I'm using a Microsoft windows 10 and using anaconda</p>

<p>Using django and a virutal environment I have a django project in:</p>

<p>projects/demo/</p>

<p>in demo I have the following folders:</p>

<p>demo
static
template 
manage.py</p>

<p>In templates I have the index.html file which I've checked using my browser and it loads.</p>

<p>in projects/demo/demo I have settings.py, urls.py,views.py</p>

<p>Here is the major edits I made that are related to the issue:</p>

<p>in settings.py:</p>

<pre><code>TEMPLATES = [
    {
        'BACKEND': 'django.template.backends.django.DjangoTemplates',
        'DIRS': os.path.join(BASE_DIR,'demo\\template\\'),
        'APP_DIRS': True,
        'OPTIONS': {
            'context_processors': [
                'django.template.context_processors.debug',
                'django.template.context_processors.request',
                'django.contrib.auth.context_processors.auth',
                'django.contrib.messages.context_processors.messages',
            ],
        },
    },
]
</code></pre>

<p>The path is correct to the file.</p>

<p>in urls.py:</p>

<pre><code>urlpatterns = [
    url(r'^admin/', admin.site.urls),
    url(r'^index/',views.index)
]
</code></pre>

<p>In views.py</p>

<pre><code>def index(request):
    return render(request,'templates/index.html',{})
</code></pre>