Skip to content

Commit d6dc8b7

Browse files
committed
[3.15] Add SimpleRouter use_regex_path argument
1 parent c85d5e7 commit d6dc8b7

File tree

2 files changed

+1
-2
lines changed

2 files changed

+1
-2
lines changed

rest_framework-stubs/routers.pyi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ class BaseRouter(metaclass=RenameRouterMethods):
4343
class SimpleRouter(BaseRouter):
4444
routes: list[Route | DynamicRoute]
4545
trailing_slash: str
46-
def __init__(self, trailing_slash: bool = ...) -> None: ...
46+
def __init__(self, trailing_slash: bool = ..., use_regex_path: bool = ...) -> None: ...
4747
def get_routes(self, viewset: type[ViewSetMixin]) -> list[Route]: ...
4848
def _get_dynamic_route(self, route: DynamicRoute, action: Any) -> Route: ...
4949
def get_method_map(self, viewset: type[ViewSetMixin], method_map: Mapping[str, str]) -> dict[str, str]: ...

scripts/stubtest/allowlist_todo.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,6 @@ rest_framework.generics.GenericAPIView.__class_getitem__
152152
rest_framework.request.Request.__class_getitem__
153153
rest_framework.response.Response.__class_getitem__
154154
rest_framework.routers.BaseRouter.is_already_registered
155-
rest_framework.routers.SimpleRouter.__init__
156155
rest_framework.schemas.openapi.AutoSchema.get_field_name
157156
rest_framework.serializers.DecimalField.__init__
158157
rest_framework.serializers.Field.__class_getitem__

0 commit comments

Comments
 (0)