MCPcopy
hub / github.com/celery/celery / _pack

Method _pack

celery/security/serialization.py:60–66  ·  view source on GitHub ↗
(self, body, content_type, content_encoding, signer, signature,
              sep=DEFAULT_SEPARATOR)

Source from the content-addressed store, hash-verified

58 payload['content_encoding'], force=True)
59
60 def _pack(self, body, content_type, content_encoding, signer, signature,
61 sep=DEFAULT_SEPARATOR):
62 fields = sep.join(
63 ensure_bytes(s) for s in [b64encode(signer), b64encode(signature),
64 content_type, content_encoding, body]
65 )
66 return b64encode(fields)
67
68 def _unpack(self, payload, sep=DEFAULT_SEPARATOR):
69 raw_payload = b64decode(ensure_bytes(payload))

Callers 1

serializeMethod · 0.95

Calls 2

b64encodeFunction · 0.90
joinMethod · 0.45

Tested by

no test coverage detected