Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1101 - 1110 of 1,707 for kjson (0.04 sec)

  1. docs/zh/docs/tutorial/response-model.md

    举个例子,当你在 NoSQL 数据库中保存了具有许多可选属性的模型,但你又不想发送充满默认值的很长的 JSON 响应。
    
    ### 使用 `response_model_exclude_unset` 参数
    
    你可以设置*路径操作装饰器*的 `response_model_exclude_unset=True` 参数:
    
    ```Python hl_lines="24"
    {!../../docs_src/response_model/tutorial004.py!}
    ```
    
    然后响应中将不会包含那些默认值,而是仅有实际设置的值。
    
    因此,如果你向*路径操作*发送 ID 为 `foo` 的商品的请求,则响应(不包括默认值)将为:
    
    ```JSON
    {
        "name": "Foo",
        "price": 50.2
    }
    ```
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 7.8K bytes
    - Viewed (0)
  2. scripts/label_approved.py

    
    settings = Settings()
    if settings.debug:
        logging.basicConfig(level=logging.DEBUG)
    else:
        logging.basicConfig(level=logging.INFO)
    logging.debug(f"Using config: {settings.json()}")
    g = Github(settings.token.get_secret_value())
    repo = g.get_repo(settings.github_repository)
    for pr in repo.get_pulls(state="open"):
        logging.info(f"Checking PR: #{pr.number}")
        pr_labels = list(pr.get_labels())
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sat Oct 12 13:58:30 UTC 2024
    - 2.2K bytes
    - Viewed (0)
  3. src/main/java/org/codelibs/fess/helper/NotificationHelper.java

            StreamUtil.split(slackWebhookUrls, "[,\\s]").of(stream -> stream.filter(StringUtil::isNotBlank).forEach(url -> {
                try (CurlResponse response = Curl.post(url).header("Content-Type", "application/json").body(body).execute()) {
                    if (response.getHttpStatusCode() == 200) {
                        if (logger.isDebugEnabled()) {
                            logger.debug("Sent {} to {}.", body, url);
                        }
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Thu Feb 22 01:37:57 UTC 2024
    - 5.1K bytes
    - Viewed (0)
  4. cni/test/testdata/pre/non_json.conf

    "This is not json"
    
    Registered: Wed Nov 06 22:53:10 UTC 2024
    - Last Modified: Thu Nov 19 23:19:19 UTC 2020
    - 60 bytes
    - Viewed (0)
  5. docs/zh/docs/tutorial/request-files.md

    /// note | "Starlette 技术细节"
    
    **FastAPI** 的 `UploadFile` 直接继承自 **Starlette** 的 `UploadFile`,但添加了一些必要功能,使之与 **Pydantic** 及 FastAPI 的其它部件兼容。
    
    ///
    
    ## 什么是 「表单数据」
    
    与 JSON 不同,HTML 表单(`<form></form>`)向服务器发送数据通常使用「特殊」的编码。
    
    **FastAPI** 要确保从正确的位置读取数据,而不是读取 JSON。
    
    /// note | "技术细节"
    
    不包含文件时,表单数据一般用 `application/x-www-form-urlencoded`「媒体类型」编码。
    
    但表单包含文件时,编码为 `multipart/form-data`。使用了 `File`,**FastAPI** 就知道要从请求体的正确位置获取文件。
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 6.9K bytes
    - Viewed (0)
  6. internal/crypto/sse-kms.go

    	if context, ok := h[xhttp.AmzServerSideEncryptionKmsContext]; ok {
    		b, err := base64.StdEncoding.DecodeString(context[0])
    		if err != nil {
    			return "", nil, err
    		}
    
    		json := jsoniter.ConfigCompatibleWithStandardLibrary
    		if err := json.Unmarshal(b, &ctx); err != nil {
    			return "", nil, err
    		}
    	}
    
    	keyID := h.Get(xhttp.AmzServerSideEncryptionKmsID)
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Tue May 07 23:55:37 UTC 2024
    - 8.5K bytes
    - Viewed (0)
  7. src/main/java/org/codelibs/fess/sso/oic/OpenIdConnectAuthenticator.java

    import com.google.api.client.http.HttpTransport;
    import com.google.api.client.http.javanet.NetHttpTransport;
    import com.google.api.client.json.JsonFactory;
    import com.google.api.client.json.JsonParser;
    import com.google.api.client.json.JsonToken;
    import com.google.api.client.json.gson.GsonFactory;
    import com.google.common.io.BaseEncoding;
    import com.google.common.io.BaseEncoding.DecodingException;
    
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Fri Oct 11 21:20:39 UTC 2024
    - 12.3K bytes
    - Viewed (0)
  8. docs/en/docs/tutorial/response-model.md

    * Add a **JSON Schema** for the response, in the OpenAPI *path operation*.
        * This will be used by the **automatic docs**.
        * It will also be used by automatic client code generation tools.
    
    But most importantly:
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 18.1K bytes
    - Viewed (0)
  9. cmd/metacache-stream.go

    	return w.streamErr
    }
    
    type metacacheBlock struct {
    	data  []byte
    	n     int
    	First string `json:"f"`
    	Last  string `json:"l"`
    	EOS   bool   `json:"eos,omitempty"`
    }
    
    func (b metacacheBlock) headerKV() map[string]string {
    	json := jsoniter.ConfigCompatibleWithStandardLibrary
    	v, err := json.Marshal(b)
    	if err != nil {
    		bugLogIf(context.Background(), err) // Unlikely
    		return nil
    	}
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Apr 04 12:04:40 UTC 2024
    - 19.5K bytes
    - Viewed (0)
  10. internal/bucket/replication/replication.go

    // https://docs.aws.amazon.com/AmazonS3/latest/dev/replication-add-config.html
    type Config struct {
    	XMLName xml.Name `xml:"ReplicationConfiguration" json:"-"`
    	Rules   []Rule   `xml:"Rule" json:"Rules"`
    	// RoleArn is being reused for MinIO replication ARN
    	RoleArn string `xml:"Role" json:"Role"`
    }
    
    // Maximum 2MiB size per replication config.
    const maxReplicationConfigSize = 2 << 20
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Mar 28 17:44:56 UTC 2024
    - 8.9K bytes
    - Viewed (0)
Back to top