MCPcopy
hub / github.com/borgbackup/borg / is_supported_msgpack

Function is_supported_msgpack

src/borg/helpers/msgpack.py:209–221  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

207
208
209def is_supported_msgpack():
210 # DO NOT CHANGE OR REMOVE! See also requirements and comments in pyproject.toml.
211 # This function now also respects the env var BORG_MSGPACK_VERSION_CHECK.
212 # Set BORG_MSGPACK_VERSION_CHECK=no to disable the version check at your own risk.
213 import msgpack
214
215 version_check = os.environ.get("BORG_MSGPACK_VERSION_CHECK", "yes").strip().lower()
216 if version_check == "no":
217 return True
218
219 if msgpack.version in []: # < add bad releases here to deny list
220 return False
221 return (1, 0, 3) <= msgpack.version[:3] <= (1, 1, 2)
222
223
224def get_limited_unpacker(kind):

Callers 1

runMethod · 0.85

Calls 1

getMethod · 0.45

Tested by

no test coverage detected