Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 118 for decompress (0.14 sec)

  1. docs/en/docs/how-to/custom-request-and-route.md

    ///
    
    First, we create a `GzipRequest` class, which will overwrite the `Request.body()` method to decompress the body in the presence of an appropriate header.
    
    If there's no `gzip` in the header, it will not try to decompress the body.
    
    That way, the same route class can handle gzip compressed or uncompressed requests.
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 27 22:39:38 UTC 2024
    - 4.3K bytes
    - Viewed (0)
  2. .github/workflows/test-redistribute.yml

            run: pip install build
          - name: Build source distribution
            env:
              TIANGOLO_BUILD_PACKAGE: ${{ matrix.package }}
            run: python -m build --sdist
          - name: Decompress source distribution
            run: |
              cd dist
              tar xvf fastapi*.tar.gz
          - name: Install test dependencies
            run: |
              cd dist/fastapi*/
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Thu Aug 08 23:34:25 UTC 2024
    - 1.8K bytes
    - Viewed (0)
  3. docs_src/custom_request_and_route/tutorial001.py

        async def body(self) -> bytes:
            if not hasattr(self, "_body"):
                body = await super().body()
                if "gzip" in self.headers.getlist("Content-Encoding"):
                    body = gzip.decompress(body)
                self._body = body
            return self._body
    
    
    class GzipRoute(APIRoute):
        def get_route_handler(self) -> Callable:
            original_route_handler = super().get_route_handler()
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri May 13 23:38:22 UTC 2022
    - 973 bytes
    - Viewed (0)
  4. okhttp/src/main/kotlin/okhttp3/internal/ws/WebSocketExtensions.kt

     * `server_max_window_bits`. This harms our ability to support these parameters:
     *
     *  * If `client_max_window_bits` is less than 15, OkHttp must close the web socket with code 1010.
     *    Otherwise it would compress values in a way that servers could not decompress.
     *  * If `server_max_window_bits` is less than 15, OkHttp will waste memory on an oversized buffer.
     *
     * See [RFC 7692, 7.1][rfc_7692] for details on negotiation process.
     *
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 8.1K bytes
    - Viewed (0)
  5. docs/select/README.md

    Install `aws-sdk-python` from AWS SDK for Python official docs [here](https://aws.amazon.com/sdk-for-python/)
    
    ### 3. Example
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Sep 29 04:28:45 UTC 2022
    - 6.5K bytes
    - Viewed (0)
  6. docs/tls/README.md

    ```
    
    ### 3.3 Use GnuTLS (for Windows) to Generate a Certificate
    
    This section describes how to use GnuTLS on Windows to generate a certificate.
    
    #### 3.3.1 Install and configure GnuTLS
    
    Download and decompress the Windows version of GnuTLS from [here](http://www.gnutls.org/download.html).
    
    Use PowerShell to add the path of the extracted GnuTLS binary to the system path:
    
    ```
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Sep 29 04:28:45 UTC 2022
    - 8.4K bytes
    - Viewed (0)
  7. okhttp-brotli/src/main/kotlin/okhttp3/brotli/internal/Uncompress.kt

    import okhttp3.ResponseBody.Companion.asResponseBody
    import okhttp3.internal.http.promisesBody
    import okio.GzipSource
    import okio.buffer
    import okio.source
    import org.brotli.dec.BrotliInputStream
    
    fun uncompress(response: Response): Response {
      if (!response.promisesBody()) {
        return response
      }
      val body = response.body
      val encoding = response.header("Content-Encoding") ?: return response
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Apr 01 13:19:01 UTC 2024
    - 1.5K bytes
    - Viewed (0)
  8. internal/config/compress/compress.go

    	cfg := Config{}
    	if err = config.CheckValidKeys(config.CompressionSubSys, kvs, DefaultKVS); err != nil {
    		return cfg, err
    	}
    
    	compress := env.Get(EnvCompressState, kvs.Get(config.Enable))
    	if compress == "" {
    		compress = env.Get(EnvCompress, "")
    	}
    	cfg.Enabled, err = config.ParseBool(compress)
    	if err != nil {
    		// Parsing failures happen due to empty KVS, ignore it.
    		if kvs.Empty() {
    			return cfg, nil
    		}
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Fri May 24 23:05:23 UTC 2024
    - 5K bytes
    - Viewed (0)
  9. src/archive/zip/register.go

    type Compressor func(w io.Writer) (io.WriteCloser, error)
    
    // A Decompressor returns a new decompressing reader, reading from r.
    // The [io.ReadCloser]'s Close method must be used to release associated resources.
    // The Decompressor itself must be safe to invoke from multiple goroutines
    // simultaneously, but each returned reader will be used only by
    // one goroutine at a time.
    type Decompressor func(r io.Reader) io.ReadCloser
    
    var flateWriterPool sync.Pool
    Registered: Tue Nov 05 11:13:11 UTC 2024
    - Last Modified: Fri Oct 13 18:36:46 UTC 2023
    - 3.7K bytes
    - Viewed (0)
  10. cmd/object-api-utils.go

    			logger.Fatal(errSelfTestFailure, "compress: error on self-test: %v", err)
    		}
    	}
    	const skip = 2<<20 + 511
    	r, _ := newS2CompressReader(bytes.NewBuffer(data), int64(len(data)), true)
    	b, err := io.ReadAll(r)
    	failOnErr(err)
    	failOnErr(r.Close())
    	// Decompression reader.
    	s2Reader := s2.NewReader(bytes.NewBuffer(b))
    	// Apply the skipLen on the decompressed stream.
    	failOnErr(s2Reader.Skip(skip))
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Aug 08 15:29:58 UTC 2024
    - 37.1K bytes
    - Viewed (0)
Back to top