Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 965 for handler (0.18 sec)

  1. fastapi/exception_handlers.py

        )
    
    
    async def request_validation_exception_handler(
        request: Request, exc: RequestValidationError
    ) -> JSONResponse:
        return JSONResponse(
            status_code=HTTP_422_UNPROCESSABLE_ENTITY,
            content={"detail": jsonable_encoder(exc.errors())},
        )
    
    
    async def websocket_request_validation_exception_handler(
        websocket: WebSocket, exc: WebSocketRequestValidationError
    ) -> None:
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sun Jun 11 19:08:14 GMT 2023
    - 1.3K bytes
    - Viewed (0)
  2. cmd/api-router.go

    }
    
    // corsHandler handler for CORS (Cross Origin Resource Sharing)
    func corsHandler(handler http.Handler) http.Handler {
    	commonS3Headers := []string{
    		xhttp.Date,
    		xhttp.ETag,
    		xhttp.ServerInfo,
    		xhttp.Connection,
    		xhttp.AcceptRanges,
    		xhttp.ContentRange,
    		xhttp.ContentEncoding,
    		xhttp.ContentLength,
    		xhttp.ContentType,
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Mar 04 18:05:56 GMT 2024
    - 22.8K bytes
    - Viewed (0)
  3. docs_src/handling_errors/tutorial006.py

    from fastapi import FastAPI, HTTPException
    from fastapi.exception_handlers import (
        http_exception_handler,
        request_validation_exception_handler,
    )
    from fastapi.exceptions import RequestValidationError
    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)}")
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sun Aug 09 11:10:33 GMT 2020
    - 928 bytes
    - Viewed (0)
  4. docs/en/docs/tutorial/dependencies/dependencies-with-yield.md

    participant client as Client
    participant handler as Exception handler
    participant dep as Dep with yield
    participant operation as Path Operation
    participant tasks as Background tasks
    
        Note over client,operation: Can raise exceptions, including HTTPException
        client ->> dep: Start request
        Note over dep: Run code up to yield
        opt raise Exception
            dep -->> handler: Raise Exception
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Feb 24 23:06:37 GMT 2024
    - 14.1K bytes
    - Viewed (0)
  5. maven-core/src/main/java/org/apache/maven/artifact/handler/manager/LegacyArtifactHandlerManager.java

            ArtifactHandler handler = allHandlers.get(type);
            if (handler == null) {
                handler = artifactHandlers.get(type);
                if (handler == null) {
                    handler = new DefaultArtifactHandler(type);
                } else {
                    allHandlers.put(type, handler);
                }
            }
            return handler;
        }
    Java
    - Registered: Sun Apr 28 03:35:10 GMT 2024
    - Last Modified: Mon Nov 27 19:18:14 GMT 2023
    - 2.4K bytes
    - Viewed (0)
  6. internal/grid/connection_test.go

    	}
    	errFatal := func(err error) {
    		t.Helper()
    		if err != nil {
    			t.Fatal(err)
    		}
    	}
    	wrapServer := func(handler http.Handler) http.Handler {
    		return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
    			t.Logf("Got a %s request for: %v", r.Method, r.URL)
    			handler.ServeHTTP(w, r)
    		})
    	}
    	connReady := make(chan struct{})
    	// We fake a local and remote server.
    	localHost := hosts[0]
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Tue Nov 21 01:09:35 GMT 2023
    - 6K bytes
    - Viewed (0)
  7. cmd/lock-rest-server.go

    	logger.FatalIf(lockRPCRefresh.Register(globalGrid.Load(), lockServer.RefreshHandler), "unable to register handler")
    	logger.FatalIf(lockRPCLock.Register(globalGrid.Load(), lockServer.LockHandler), "unable to register handler")
    	logger.FatalIf(lockRPCUnlock.Register(globalGrid.Load(), lockServer.UnlockHandler), "unable to register handler")
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Tue Nov 21 01:09:35 GMT 2023
    - 5.9K bytes
    - Viewed (0)
  8. cmd/test-utils_test.go

    // Usage hint: Should be used at the end of the API end points tests (ex: check the last few lines of `testAPIListObjectPartsHandler`),
    // need a sample HTTP request to be sent as argument so that the relevant handler is called, the handler registration is expected
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:06:57 GMT 2024
    - 75.7K bytes
    - Viewed (0)
  9. analysis/analysis-api-fe10/src/org/jetbrains/kotlin/analysis/api/descriptors/CliFe10AnalysisFacade.kt

                facade = this,
                handler.resolveSession.orThrowResolutionNotPerformedError(),
                handler.deprecationResolver.orThrowResolutionNotPerformedError(),
                handler.callResolver.orThrowResolutionNotPerformedError(),
                handler.kotlinToResolvedCallTransformer.orThrowResolutionNotPerformedError(),
                handler.overloadingConflictResolver.orThrowResolutionNotPerformedError(),
    Plain Text
    - Registered: Fri Apr 26 08:18:10 GMT 2024
    - Last Modified: Fri Jan 26 16:20:19 GMT 2024
    - 7K bytes
    - Viewed (0)
  10. cmd/peer-rest-server.go

    	logger.FatalIf(getMetacacheListingRPC.Register(gm, server.GetMetacacheListingHandler), "unable to register handler")
    	logger.FatalIf(getMetricsRPC.Register(gm, server.GetMetricsHandler), "unable to register handler")
    	logger.FatalIf(getNetInfoRPC.Register(gm, server.GetNetInfoHandler), "unable to register handler")
    	logger.FatalIf(getOSInfoRPC.Register(gm, server.GetOSInfoHandler), "unable to register handler")
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 51.8K bytes
    - Viewed (0)
Back to top