Search Options

Results per page
Sort
Preferred Languages
Advance

Results 221 - 230 of 694 for statusFn (0.08 sec)

  1. docs_src/websockets/tutorial002.py

    from typing import Union
    
    from fastapi import (
        Cookie,
        Depends,
        FastAPI,
        Query,
        WebSocket,
        WebSocketException,
        status,
    )
    from fastapi.responses import HTMLResponse
    
    app = FastAPI()
    
    html = """
    <!DOCTYPE html>
    <html>
        <head>
            <title>Chat</title>
        </head>
        <body>
            <h1>WebSocket Chat</h1>
            <form action="" onsubmit="sendMessage(event)">
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Nov 13 16:10:54 UTC 2022
    - 2.8K bytes
    - Viewed (0)
  2. fastapi/__init__.py

    """FastAPI framework, high performance, easy to learn, fast to code, ready for production"""
    
    __version__ = "0.115.4"
    
    from starlette import status as status
    
    from .applications import FastAPI as FastAPI
    from .background import BackgroundTasks as BackgroundTasks
    from .datastructures import UploadFile as UploadFile
    from .exceptions import HTTPException as HTTPException
    from .exceptions import WebSocketException as WebSocketException
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 27 21:51:55 UTC 2024
    - 1.1K bytes
    - Viewed (0)
  3. docs_src/security/tutorial005.py

        current_user: User = Security(get_current_active_user, scopes=["items"]),
    ):
        return [{"item_id": "Foo", "owner": current_user.username}]
    
    
    @app.get("/status/")
    async def read_system_status(current_user: User = Depends(get_current_user)):
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Mon May 20 17:37:28 UTC 2024
    - 5.2K bytes
    - Viewed (0)
  4. docs_src/security/tutorial005_an.py

    ):
        return [{"item_id": "Foo", "owner": current_user.username}]
    
    
    @app.get("/status/")
    async def read_system_status(current_user: Annotated[User, Depends(get_current_user)]):
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Mon May 20 17:37:28 UTC 2024
    - 5.3K bytes
    - Viewed (0)
  5. cmd/site-replication.go

    			return errSRInvalidRequest(errInvalidArgument)
    		}
    		userReq := *change.UserReq
    		if userReq.Status != "" && userReq.SecretKey == "" {
    			// Status is set without secretKey updates means we are
    			// only changing the account status.
    			_, err = globalIAMSys.SetUserStatus(ctx, change.AccessKey, userReq.Status)
    		} else {
    			// We don't allow internal user creation with LDAP enabled for now
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Aug 15 12:04:40 UTC 2024
    - 185.1K bytes
    - Viewed (0)
  6. tests/test_tutorial/test_security/test_tutorial005_py310.py

        response = client.get(
            "/status/", headers={"Authorization": f"Bearer {access_token}"}
        )
        assert response.status_code == 200, response.text
        assert response.json() == {"status": "ok"}
    
    
    @needs_py310
    def test_read_system_status_no_token(client: TestClient):
        response = client.get("/status/")
        assert response.status_code == 401, response.text
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Wed Mar 13 19:07:10 UTC 2024
    - 16.3K bytes
    - Viewed (0)
  7. tests/test_tutorial/test_security/test_tutorial005_py39.py

        response = client.get(
            "/status/", headers={"Authorization": f"Bearer {access_token}"}
        )
        assert response.status_code == 200, response.text
        assert response.json() == {"status": "ok"}
    
    
    @needs_py39
    def test_read_system_status_no_token(client: TestClient):
        response = client.get("/status/")
        assert response.status_code == 401, response.text
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Wed Mar 13 19:07:10 UTC 2024
    - 16.3K bytes
    - Viewed (0)
  8. internal/logger/target/kafka/kafka.go

    	msg := sarama.ProducerMessage{
    		Topic: h.kconfig.Topic,
    		Value: sarama.ByteEncoder(logJSON),
    	}
    	_, _, err = h.producer.SendMessage(&msg)
    	if err != nil {
    		atomic.StoreInt32(&h.status, statusOffline)
    	} else {
    		atomic.StoreInt32(&h.status, statusOnline)
    	}
    	return err
    }
    
    // Init initialize kafka target
    func (h *Target) init() error {
    	if os.Getenv("_MINIO_KAFKA_DEBUG") != "" {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Fri Sep 06 23:06:30 UTC 2024
    - 10.2K bytes
    - Viewed (0)
  9. fastapi/routing.py

                Doc(
                    """
                    The default status code to be used for the response.
    
                    You could override the status code by returning a response directly.
    
                    Read more about it in the
                    [FastAPI docs for Response Status Code](https://fastapi.tiangolo.com/tutorial/response-status-code/).
                    """
                ),
            ] = None,
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sat Oct 12 09:44:57 UTC 2024
    - 172.1K bytes
    - Viewed (0)
  10. internal/bucket/replication/datatypes.go

    	Failed StatusType = "FAILED"
    
    	// Replica - this is a replica.
    	Replica StatusType = "REPLICA"
    )
    
    // String returns string representation of status
    func (s StatusType) String() string {
    	return string(s)
    }
    
    // Empty returns true if this status is not set
    func (s StatusType) Empty() bool {
    	return string(s) == ""
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Fri Mar 08 19:08:18 UTC 2024
    - 1.5K bytes
    - Viewed (0)
Back to top