docs: def finish(self):
          """
          Finish the compressor. This will emit the remaining output data and
          transition the compressor to a completed state. The compressor cannot
          be used again after this point, and must be replaced.
          """
          chunks = []
          while lib.BrotliEncoderIsFinished(self._encoder) == lib.BROTLI_FALSE:
              chunks.append(self._compress(b'', lib.BROTLI_OPERATION_FINISH))
  
          return b''.join(chunks)