Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 282 for main (0.18 sec)

  1. docs_src/app_testing/app_b_py310/main.py

    }
    
    app = FastAPI()
    
    
    class Item(BaseModel):
        id: str
        title: str
        description: str | None = None
    
    
    @app.get("/items/{item_id}", response_model=Item)
    async def read_main(item_id: str, x_token: str = Header()):
        if x_token != fake_secret_token:
            raise HTTPException(status_code=400, detail="Invalid X-Token header")
        if item_id not in fake_db:
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Jan 09 14:44:08 GMT 2024
    - 1.1K bytes
    - Viewed (0)
  2. docs_src/app_testing/app_b/main.py

    }
    
    app = FastAPI()
    
    
    class Item(BaseModel):
        id: str
        title: str
        description: Union[str, None] = None
    
    
    @app.get("/items/{item_id}", response_model=Item)
    async def read_main(item_id: str, x_token: str = Header()):
        if x_token != fake_secret_token:
            raise HTTPException(status_code=400, detail="Invalid X-Token header")
        if item_id not in fake_db:
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Jan 09 14:44:08 GMT 2024
    - 1.1K bytes
    - Viewed (0)
  3. tests/main.py

    @app.get("/path/param-minlength/{item_id}")
    def get_path_param_min_length(item_id: str = Path(min_length=3)):
        return item_id
    
    
    @app.get("/path/param-maxlength/{item_id}")
    def get_path_param_max_length(item_id: str = Path(max_length=3)):
        return item_id
    
    
    @app.get("/path/param-min_maxlength/{item_id}")
    def get_path_param_min_max_length(item_id: str = Path(max_length=3, min_length=2)):
        return item_id
    
    
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 21:56:59 GMT 2024
    - 4.3K bytes
    - Viewed (0)
  4. docs_src/settings/app03_an/main.py

    Sebastián Ramírez <******@****.***> 1698179166 +0400
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Oct 24 20:26:06 GMT 2023
    - 451 bytes
    - Viewed (0)
  5. .github/actions/notify-translations/app/main.py

            comment_id=comment_id,
            body=body,
        )
        response = UpdateCommentResponse.parse_obj(data)
        return response.data.updateDiscussionComment.comment
    
    
    if __name__ == "__main__":
        settings = Settings()
        if settings.input_debug:
            logging.basicConfig(level=logging.DEBUG)
        else:
            logging.basicConfig(level=logging.INFO)
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Wed Sep 27 23:01:46 GMT 2023
    - 12.4K bytes
    - Viewed (0)
  6. .github/actions/people/app/main.py

    def get_top_users(
        *,
        counter: Counter,
        authors: Dict[str, Author],
        skip_users: Container[str],
        min_count: int = 2,
    ):
        users = []
        for commenter, count in counter.most_common(50):
            if commenter in skip_users:
                continue
            if count >= min_count:
                author = authors[commenter]
                users.append(
                    {
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Mar 26 17:38:21 GMT 2024
    - 19.2K bytes
    - Viewed (1)
  7. docs_src/settings/app03_an_py39/main.py

    Sebastián Ramírez <******@****.***> 1698179166 +0400
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Oct 24 20:26:06 GMT 2023
    - 462 bytes
    - Viewed (0)
  8. docs_src/settings/app02_an_py39/main.py

    Sebastián Ramírez <******@****.***> 1698179166 +0400
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Oct 24 20:26:06 GMT 2023
    - 445 bytes
    - Viewed (0)
  9. docs_src/settings/app03/main.py

    Sebastián Ramírez <******@****.***> 1698179166 +0400
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Oct 24 20:26:06 GMT 2023
    - 412 bytes
    - Viewed (0)
  10. .github/actions/comment-docs-preview-in-pr/app/main.py

    
    class PartialGithubEventWorkflowRun(BaseModel):
        head_commit: PartialGithubEventHeadCommit
    
    
    class PartialGithubEvent(BaseModel):
        workflow_run: PartialGithubEventWorkflowRun
    
    
    if __name__ == "__main__":
        logging.basicConfig(level=logging.INFO)
        settings = Settings()
        logging.info(f"Using config: {settings.json()}")
        g = Github(settings.input_token.get_secret_value())
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Jan 09 15:02:53 GMT 2024
    - 2.1K bytes
    - Viewed (0)
Back to top