Consul-kv

Latest version: v0.7.4

Safety actively analyzes 682404 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

0.7.4

Adds decode_utf8 parameter to get calls so that binary data can be retrieved.
Before the assumption was made that all data was UTF-8 text. With this new parameter also binary blobs can be retrieved.

In [3]: from consul_kv import Connection
...: conn = Connection(endpoint='http://localhost:8500/v1/')

In [4]: conn.get('nontext-test', decode_utf8=False)
Out[4]: {'nontext-test': b'\x00\x01\x02\x03\x04\x05\xde'}


Thanks to [ulidtko](https://github.com/ulidtko) for the feedback.

0.7.3

Add verb to put_dict so it can use CAS to only create the keys in the mapping if they do not exist yet.

In [2]: d = {'k1': 'v1', 'kv2': 'v2'}
In [3]: c = Connection()
In [4]: c.put_dict(d, verb='cas')
In [5]: c.put_dict(d, verb='cas')
HTTPError: HTTP Error 409: Conflict

0.7.2

Breaks compatiblity with previous versions.

The default endpoint is now

DEFAULT_ENDPOINT = 'http://localhost:8500/v1/'


instead of

DEFAULT_KV_ENDPOINT = 'http://localhost:8500/v1/kv/'


This makes it more sensible to use conn.get_meta. otherwise you'd have
to manually specify the kv-less default endpoint and pass 'kv/' to all
kv items you'd want to interact with. See [20](https://github.com/vdloo/consul-kv/pull/20)

The transaction default endpoint is now `http://localhost:8500/v1/txn`.
Note that there is no trailing slash for this endpoint.

0.5

Adds [CAS functionality](https://github.com/vdloo/consul-kv/pull/14). Thanks [jakobdalsgaard](https://github.com/jakobdalsgaard)!

0.4

Allow to [recurse nested levels](https://github.com/vdloo/consul-kv/pull/10). Thanks [nadirollo](https://github.com/nadirollo)!

Links

Releases

Has known vulnerabilities

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.