Skip to content

Failed to find path results in ValueError on the root path #2195

@vladimirnani

Description

@vladimirnani

When connecting via ws to the app new WebSocket("ws://localhost:8000/");

Application fails with

    raise ValueError("No route found for path %r." % path)
ValueError: No route found for path ''.
application = ProtocolTypeRouter({
    "http": django_asgi_app,
    "websocket": AuthMiddlewareStack(
        URLRouter(
            [re_path(r'^ws/something/$', Consumer.as_asgi()),]
        )
    ),
})

Shouldn't it raise Resolver404 instead?

channels==4.2.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions