- Sort Score
- Result 10 results
- Languages All
Results 1251 - 1260 of 7,824 for Export (0.17 sec)
-
docs_src/dependencies/tutorial008d_an_py39.py
from typing import Annotated from fastapi import Depends, FastAPI, HTTPException app = FastAPI() class InternalError(Exception): pass def get_username(): try: yield "Rick" except InternalError: print("We don't swallow the internal error here, we raise again 😎") raise @app.get("/items/{item_id}") def get_item(item_id: str, username: Annotated[str, Depends(get_username)]):
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Feb 24 23:06:37 UTC 2024 - 734 bytes - Viewed (0) -
docs_src/dependencies/tutorial012_an_py39.py
from fastapi import Depends, FastAPI, Header, HTTPException from typing_extensions import Annotated async def verify_token(x_token: Annotated[str, Header()]): if x_token != "fake-super-secret-token": raise HTTPException(status_code=400, detail="X-Token header invalid") async def verify_key(x_key: Annotated[str, Header()]): if x_key != "fake-super-secret-key": raise HTTPException(status_code=400, detail="X-Key header invalid")
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Mar 18 12:29:59 UTC 2023 - 756 bytes - Viewed (0) -
docs_src/path_operation_configuration/tutorial004_py310.py
from fastapi import FastAPI from pydantic import BaseModel app = FastAPI() class Item(BaseModel): name: str description: str | None = None price: float tax: float | None = None tags: set[str] = set() @app.post("/items/", response_model=Item, summary="Create an item") async def create_item(item: Item): """ Create an item with all the information: - **name**: each item must have a name
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jan 07 14:11:31 UTC 2022 - 638 bytes - Viewed (0) -
tests/test_tutorial/test_custom_response/test_tutorial004.py
from fastapi.testclient import TestClient from docs_src.custom_response.tutorial004 import app client = TestClient(app) html_contents = """ <html> <head> <title>Some HTML in here</title> </head> <body> <h1>Look ma! HTML!</h1> </body> </html> """ def test_get_custom_response(): response = client.get("/items/")
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 1.2K bytes - Viewed (0) -
docs/extensions/s3zip/examples/boto3/main.py
#!/usr/bin/env/python import boto3 from botocore.client import Config s3 = boto3.client('s3', endpoint_url='http://localhost:9000', aws_access_key_id='YOUR-ACCESSKEYID', aws_secret_access_key='YOUR-SECRETACCESSKEY', config=Config(signature_version='s3v4'), region_name='us-east-1') def _add_header(request, **kwargs): request.headers.add_header('x-minio-extract', 'true')
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Aug 04 21:15:45 UTC 2021 - 771 bytes - Viewed (0) -
guava/src/com/google/common/collect/ImmutableSortedMap.java
import com.google.common.annotations.J2ktIncompatible; import com.google.errorprone.annotations.CanIgnoreReturnValue; import com.google.errorprone.annotations.DoNotCall; import java.io.InvalidObjectException; import java.io.ObjectInputStream; import java.util.AbstractMap; import java.util.Comparator; import java.util.Map; import java.util.NavigableMap; import java.util.SortedMap; import java.util.Spliterator;
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 50.4K bytes - Viewed (0) -
android/guava/src/com/google/common/cache/CacheBuilder.java
import java.lang.ref.SoftReference; import java.lang.ref.WeakReference; import java.time.Duration; import java.util.ConcurrentModificationException; import java.util.IdentityHashMap; import java.util.Map; import java.util.concurrent.TimeUnit; import java.util.logging.Level; import java.util.logging.Logger; import javax.annotation.CheckForNull; /** * A builder of {@link LoadingCache} and {@link Cache} instances. *
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 19:07:49 UTC 2024 - 52K bytes - Viewed (0) -
src/main/java/jcifs/smb1/smb1/SmbFileOutputStream.java
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ package jcifs.smb1.smb1; import java.net.URL; import java.io.OutputStream; import java.io.IOException; import java.net.UnknownHostException; import jcifs.smb1.util.LogStream; import java.net.MalformedURLException; /** * This <code>OutputStream</code> can write bytes to a file on an SMB file server. */
Registered: Sun Nov 03 00:10:13 UTC 2024 - Last Modified: Fri Mar 22 21:10:40 UTC 2019 - 9.2K bytes - Viewed (0) -
src/main/java/org/codelibs/fess/suggest/converter/KatakanaToAlphabetConverter.java
* governing permissions and limitations under the License. */ package org.codelibs.fess.suggest.converter; import java.io.IOException; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; import com.ibm.icu.text.Transliterator; public class KatakanaToAlphabetConverter implements ReadingConverter { private final Map<String, String[]> convertMap;
Registered: Fri Nov 08 09:08:12 UTC 2024 - Last Modified: Thu Feb 22 01:36:54 UTC 2024 - 9.4K bytes - Viewed (0) -
src/main/java/org/codelibs/fess/app/pager/FileConfigPager.java
* either express or implied. See the License for the specific language * governing permissions and limitations under the License. */ package org.codelibs.fess.app.pager; import java.io.Serializable; import java.util.List; import org.codelibs.fess.util.ComponentUtil; public class FileConfigPager implements Serializable { private static final long serialVersionUID = 1L;
Registered: Thu Oct 31 13:40:30 UTC 2024 - Last Modified: Thu Feb 22 01:37:57 UTC 2024 - 3.8K bytes - Viewed (0)