1
다음 경로를 설정하고 rest API를/rest와 일치시킵니다.특정 경로가 일치 할 때 404를 표시합니다.
routes = [
PathPrefixRoute('/rest', [
Route('/customers', handler='app.handlers.CustomerHandler:list',
methods=['GET']),
# some other /rest routers
Route('/<:.*>', ?) # this route should execute abort(404)
]),
Route('/<page:.*>', handler='app.handlers.PageHandler', methods=['GET'])
]
누군가가 내가 404
보여주고 싶은 /rest/does_not_exists
URL이 경로에서 중단 (404)를 호출 할 수있는 방법이 있나요 아니면 내가 그 핸들러를 작성해야 액세스하는 경우?