Search Options

Results per page
Sort
Preferred Languages
Advance

Results 541 - 550 of 944 for fooo (0.08 sec)

  1. docs_src/response_change_status_code/tutorial001.py

    from fastapi import FastAPI, Response, status
    
    app = FastAPI()
    
    tasks = {"foo": "Listen to the Bar Fighters"}
    
    
    @app.put("/get-or-create-task/{task_id}", status_code=200)
    def get_or_create_task(task_id: str, response: Response):
        if task_id not in tasks:
            tasks[task_id] = "This didn't exist before"
            response.status_code = status.HTTP_201_CREATED
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Thu Mar 26 19:09:53 UTC 2020
    - 391 bytes
    - Viewed (0)
  2. tests/test_tutorial/test_additional_status_codes/test_tutorial001_py310.py

        from docs_src.additional_status_codes.tutorial001_py310 import app
    
        client = TestClient(app)
        return client
    
    
    @needs_py310
    def test_update(client: TestClient):
        response = client.put("/items/foo", json={"name": "Wrestlers"})
        assert response.status_code == 200, response.text
        assert response.json() == {"name": "Wrestlers", "size": None}
    
    
    @needs_py310
    def test_create(client: TestClient):
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sat Mar 18 12:29:59 UTC 2023
    - 738 bytes
    - Viewed (0)
  3. docs_src/dependencies/tutorial002_an_py310.py

    from typing import Annotated
    
    from fastapi import Depends, FastAPI
    
    app = FastAPI()
    
    
    fake_items_db = [{"item_name": "Foo"}, {"item_name": "Bar"}, {"item_name": "Baz"}]
    
    
    class CommonQueryParams:
        def __init__(self, q: str | None = None, skip: int = 0, limit: int = 100):
            self.q = q
            self.skip = skip
            self.limit = limit
    
    
    @app.get("/items/")
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sat Mar 18 12:29:59 UTC 2023
    - 664 bytes
    - Viewed (0)
  4. tests/test_tutorial/test_dependencies/test_tutorial008b_an.py

    from fastapi.testclient import TestClient
    
    from docs_src.dependencies.tutorial008b_an import app
    
    client = TestClient(app)
    
    
    def test_get_no_item():
        response = client.get("/items/foo")
        assert response.status_code == 404, response.text
        assert response.json() == {"detail": "Item not found"}
    
    
    def test_owner_error():
        response = client.get("/items/plumbus")
        assert response.status_code == 400, response.text
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Tue Dec 26 20:37:34 UTC 2023
    - 700 bytes
    - Viewed (0)
  5. src/main/webapp/WEB-INF/view/admin/relatedcontent/admin_relatedcontent_details.jsp

                    </div>
                </la:form>
    
            </section>
        </div>
        <jsp:include page="/WEB-INF/view/common/admin/footer.jsp"></jsp:include>
    </div>
    <jsp:include page="/WEB-INF/view/common/admin/foot.jsp"></jsp:include>
    </body>
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Thu Feb 13 07:47:04 UTC 2020
    - 4.8K bytes
    - Viewed (0)
  6. src/main/webapp/WEB-INF/view/admin/reqheader/admin_reqheader.jsp

                    </div>
                </div>
            </section>
        </div>
        <jsp:include page="/WEB-INF/view/common/admin/footer.jsp"></jsp:include>
    </div>
    <jsp:include page="/WEB-INF/view/common/admin/foot.jsp"></jsp:include>
    </body>
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Tue Mar 24 13:43:18 UTC 2020
    - 5.5K bytes
    - Viewed (0)
  7. src/main/webapp/WEB-INF/view/admin/reqheader/admin_reqheader_details.jsp

                    </div>
                </la:form>
            </section>
        </div>
        <jsp:include page="/WEB-INF/view/common/admin/footer.jsp"></jsp:include>
    </div>
    <jsp:include page="/WEB-INF/view/common/admin/foot.jsp"></jsp:include>
    </body>
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Thu Feb 13 07:47:04 UTC 2020
    - 4.6K bytes
    - Viewed (0)
  8. guava-tests/test/com/google/common/collect/SetsTest.java

        assertTrue(set.isEmpty());
        set.add(new Derived("foo"));
        set.add(new Derived("bar"));
        assertThat(set).containsExactly(new Derived("bar"), new Derived("foo")).inOrder();
      }
    
      public void testNewTreeSetEmptyNonGeneric() {
        TreeSet<LegacyComparable> set = Sets.newTreeSet();
        assertTrue(set.isEmpty());
        set.add(new LegacyComparable("foo"));
        set.add(new LegacyComparable("bar"));
        assertThat(set)
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 48.6K bytes
    - Viewed (0)
  9. docs_src/extending_openapi/tutorial001.py

    from fastapi import FastAPI
    from fastapi.openapi.utils import get_openapi
    
    app = FastAPI()
    
    
    @app.get("/items/")
    async def read_items():
        return [{"name": "Foo"}]
    
    
    def custom_openapi():
        if app.openapi_schema:
            return app.openapi_schema
        openapi_schema = get_openapi(
            title="Custom title",
            version="2.5.0",
            summary="This is a very custom OpenAPI schema",
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jun 30 18:25:16 UTC 2023
    - 737 bytes
    - Viewed (0)
  10. docs_src/additional_responses/tutorial004.py

    )
    async def read_item(item_id: str, img: Union[bool, None] = None):
        if img:
            return FileResponse("image.png", media_type="image/png")
        else:
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sat May 14 11:59:59 UTC 2022
    - 701 bytes
    - Viewed (0)
Back to top