Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 28 for Exceptionhandler (0.08 sec)

  1. impl/maven-core/src/main/java/org/apache/maven/exception/DefaultExceptionHandler.java

    // CycleDetectedInPluginGraphException;
    
    /**
     * Transform an exception into useful end-user message.
     */
    @Named
    @Singleton
    public class DefaultExceptionHandler implements ExceptionHandler {
        @Override
        public ExceptionSummary handleException(Throwable exception) {
            return handle("", exception);
        }
    
        private ExceptionSummary handle(String message, Throwable exception) {
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Sat Apr 05 11:52:05 UTC 2025
    - 10.9K bytes
    - Viewed (0)
  2. impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/mvn/MavenInvoker.java

    import org.apache.maven.cling.transfer.SimplexTransferListener;
    import org.apache.maven.cling.transfer.Slf4jMavenTransferListener;
    import org.apache.maven.exception.DefaultExceptionHandler;
    import org.apache.maven.exception.ExceptionHandler;
    import org.apache.maven.exception.ExceptionSummary;
    import org.apache.maven.execution.DefaultMavenExecutionRequest;
    import org.apache.maven.execution.ExecutionListener;
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Thu Sep 11 17:20:46 UTC 2025
    - 28.2K bytes
    - Viewed (0)
  3. compat/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java

    import org.apache.maven.di.Injector;
    import org.apache.maven.eventspy.internal.EventSpyDispatcher;
    import org.apache.maven.exception.DefaultExceptionHandler;
    import org.apache.maven.exception.ExceptionHandler;
    import org.apache.maven.exception.ExceptionSummary;
    import org.apache.maven.execution.DefaultMavenExecutionRequest;
    import org.apache.maven.execution.ExecutionListener;
    Registered: Sun Dec 28 03:35:09 UTC 2025
    - Last Modified: Mon Oct 27 13:24:03 UTC 2025
    - 78.1K bytes
    - Viewed (0)
  4. fastapi/applications.py

    from starlette.requests import Request
    from starlette.responses import HTMLResponse, JSONResponse, Response
    from starlette.routing import BaseRoute
    from starlette.types import ASGIApp, ExceptionHandler, Lifespan, Receive, Scope, Send
    from typing_extensions import deprecated
    
    AppType = TypeVar("AppType", bound="FastAPI")
    
    
    class FastAPI(Starlette):
        """
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Wed Dec 17 21:25:59 UTC 2025
    - 176.3K bytes
    - Viewed (0)
  5. tests/test_validation_error_context.py

    app.mount(path="/sub", app=sub_app)
    
    
    @app.exception_handler(RequestValidationError)
    @sub_app.exception_handler(RequestValidationError)
    async def request_validation_handler(request: Request, exc: RequestValidationError):
        captured_exception.capture(exc)
        raise exc
    
    
    @app.exception_handler(ResponseValidationError)
    @sub_app.exception_handler(ResponseValidationError)
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 06 12:21:57 UTC 2025
    - 4.7K bytes
    - Viewed (0)
  6. docs_src/handling_errors/tutorial006_py39.py

    from starlette.exceptions import HTTPException as StarletteHTTPException
    
    app = FastAPI()
    
    
    @app.exception_handler(StarletteHTTPException)
    async def custom_http_exception_handler(request, exc):
        print(f"OMG! An HTTP error!: {repr(exc)}")
        return await http_exception_handler(request, exc)
    
    
    @app.exception_handler(RequestValidationError)
    async def validation_exception_handler(request, exc):
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Wed Dec 17 20:41:43 UTC 2025
    - 928 bytes
    - Viewed (0)
  7. docs_src/handling_errors/tutorial004_py39.py

    from starlette.exceptions import HTTPException as StarletteHTTPException
    
    app = FastAPI()
    
    
    @app.exception_handler(StarletteHTTPException)
    async def http_exception_handler(request, exc):
        return PlainTextResponse(str(exc.detail), status_code=exc.status_code)
    
    
    @app.exception_handler(RequestValidationError)
    async def validation_exception_handler(request, exc: RequestValidationError):
        message = "Validation errors:"
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Wed Dec 17 20:41:43 UTC 2025
    - 920 bytes
    - Viewed (0)
  8. docs_src/handling_errors/tutorial003_py39.py

    from fastapi import FastAPI, Request
    from fastapi.responses import JSONResponse
    
    
    class UnicornException(Exception):
        def __init__(self, name: str):
            self.name = name
    
    
    app = FastAPI()
    
    
    @app.exception_handler(UnicornException)
    async def unicorn_exception_handler(request: Request, exc: UnicornException):
        return JSONResponse(
            status_code=418,
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Wed Dec 17 20:41:43 UTC 2025
    - 626 bytes
    - Viewed (0)
  9. docs_src/handling_errors/tutorial005_py39.py

    from fastapi.encoders import jsonable_encoder
    from fastapi.exceptions import RequestValidationError
    from fastapi.responses import JSONResponse
    from pydantic import BaseModel
    
    app = FastAPI()
    
    
    @app.exception_handler(RequestValidationError)
    async def validation_exception_handler(request: Request, exc: RequestValidationError):
        return JSONResponse(
            status_code=422,
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Wed Dec 17 20:41:43 UTC 2025
    - 626 bytes
    - Viewed (0)
  10. docs/en/docs/reference/fastapi.md

                - put
                - post
                - delete
                - options
                - head
                - patch
                - trace
                - on_event
                - middleware
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Thu Apr 18 19:53:19 UTC 2024
    - 701 bytes
    - Viewed (0)
Back to top