Q:

ViewDoesNotExist in Django

I am trying to solve a problem: Django tells me my view does not exist, yet I have made a view that should be loaded with the same name. I have the following error:
ViewDoesNotExist at /
Could not import Gastenboek.views.main.as_view(). Parent module 
Gastenboek.views.main does not exist.

traceback

Environment:

Request Method: GET
Request URL: http://127.0.0.1:8000/

Django Version: 1.6.1
Python Version: 3.3.3
Installed Applications:
('django.contrib.admin',
 'django.contrib.auth',
 'django.contrib.contenttypes',
 'django.contrib.sessions',
 'django.contrib.messages',
 'django.contrib.staticfiles',
 'Gastenboek')
Installed Middleware:
('django.contrib.sessions.middleware.SessionMiddleware',
 'django.middleware.common.CommonMiddleware',
 'django.middleware.csrf.CsrfViewMiddleware',
 'django.contrib.auth.middleware.AuthenticationMiddleware',
 'django.contrib.messages.middleware.MessageMiddleware',
 'django.middleware.clickjacking.XFrameOptionsMiddleware')

Traceback:
File "C:\Python33\lib\site-packages\django\core\handlers\base.py" in get_response
  101.                 resolver_match = resolver.resolve(request.path_info)
File "C:\Python33\lib\site-packages\django\core\urlresolvers.py" in resolve
  320.                     sub_match = pattern.resolve(new_path)
File "C:\Python33\lib\site-packages\django\core\urlresolvers.py" in resolve
  222.             return ResolverMatch(self.callback, args, kwargs, self.name)
File "C:\Python33\lib\site-packages\django\core\urlresolvers.py" in callback
  229.         self._callback = get_callable(self._callback_str)
File "C:\Python33\lib\site-packages\django\utils\functional.py" in wrapper
  32.         result = func(*args)
File "C:\Python33\lib\site-packages\django\core\urlresolvers.py" in get_callable
  103.                     (lookup_view, mod_name))

Exception Type: ViewDoesNotExist at /
Exception Value: Could not import Gastenboek.views.main.as_view(). Parent module Gastenboek.views.main does not exist.

views
from django.shortcuts import render
from django.views.generic import ListView
from Gastenboek.models import *

class main(ListView):
    model = Bericht
    template_name = 'template/bericht_lijst.html'
    paginate_by = 10
    context_object_name = "bericht_lijst"
# Create your views here.

models
from django.db import models
from django.contrib.auth.models import User
from django.contrib import admin

class Bericht(models.Model):
    titel = models.CharField(max_length=50)
    auteur = models.ForeignKey(User, blank=True)
    email = models.EmailField(max_length=75)
    inhoud = models.TextField(max_length=10000, blank=True)
    datum = models.DateTimeField(auto_now_add=True)

    def __str__(self):
        return str(self.auteur) + " : " + str(self.titel)

    class Meta:
        verbose_name_plural = "berichten"

class BerichtAdmin(admin.ModelAdmin):
    list_display = ["auteur", "datum", "titel"]
    list_filter = ["datum", "auteur"]

admin.site.register(Bericht, BerichtAdmin)

url.py
from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()

urlpatterns = patterns('',
    # Examples:
    # url(r'^$', 'Niels.views.home', name='home'),
    # url(r'^blog/', include('blog.urls')),

    url(r'^admin/', include(admin.site.urls)),
    (r"^(\d+)/$",'Gastenboek.views.main.as_view()'),
(r"", 'Gastenboek.views.main.as_view()'),
)

A:

don't use quotes with .as_view()
from GastenBoek import views

(r"^(\d+)/$", views.main.as_view()),
(r"", views.main.as_view()),

