[Answer]-(Visual Studio) Django error when running on local host.. used a template?

1👍

In Your views try removing RequestContext

return render(request, 'app/index.html',

    {
        'title':'Home Page',
        'year':datetime.now().year,
    }
)

instead of

return render(
    request,
    'app/index.html',

    RequestContext(request,
    {
        'title':'Home Page',
        'year':datetime.now().year,
    })
)

looks like a PTVS bug
refer to
http://pytools.codeplex.com/workitem/2653

Leave a comment