docs: fix bytes -> str in data-structures docs

This commit is contained in:
Thomas Waldmann 2022-05-30 23:22:48 +02:00
parent 58009f6773
commit 421d4bdfb0
1 changed files with 19 additions and 19 deletions

View File

@ -329,17 +329,17 @@ or modified. It looks like this:
.. code-block:: python .. code-block:: python
{ {
b'version': 1, 'version': 1,
b'timestamp': b'2017-05-05T12:42:23.042864', 'timestamp': '2017-05-05T12:42:23.042864',
b'item_keys': [b'acl_access', b'acl_default', ...], 'item_keys': ['acl_access', 'acl_default', ...],
b'config': {}, 'config': {},
b'archives': { 'archives': {
b'2017-05-05-system-backup': { '2017-05-05-system-backup': {
b'id': b'<32 byte binary object ID>', 'id': b'<32 byte binary object ID>',
b'time': b'2017-05-05T12:42:22.942864', 'time': '2017-05-05T12:42:22.942864',
}, },
}, },
b'tam': ..., 'tam': ...,
} }
The *version* field can be either 1 or 2. The versions differ in the The *version* field can be either 1 or 2. The versions differ in the
@ -393,15 +393,15 @@ The *config* key stores the feature flags enabled on a repository:
.. code-block:: python .. code-block:: python
config = { config = {
b'feature_flags': { 'feature_flags': {
b'read': { 'read': {
b'mandatory': [b'some_feature'], 'mandatory': ['some_feature'],
}, },
b'check': { 'check': {
b'mandatory': [b'other_feature'], 'mandatory': ['other_feature'],
} }
b'write': ..., 'write': ...,
b'delete': ... 'delete': ...
}, },
} }
@ -1220,9 +1220,9 @@ transaction ID in the file names. Integrity data is stored in a third file
.. code-block:: python .. code-block:: python
{ {
b'version': 2, 'version': 2,
b'hints': b'{"algorithm": "XXH64", "digests": {"final": "411208db2aa13f1a"}}', 'hints': '{"algorithm": "XXH64", "digests": {"final": "411208db2aa13f1a"}}',
b'index': b'{"algorithm": "XXH64", "digests": {"HashHeader": "846b7315f91b8e48", "final": "cb3e26cadc173e40"}}' 'index': '{"algorithm": "XXH64", "digests": {"HashHeader": "846b7315f91b8e48", "final": "cb3e26cadc173e40"}}'
} }
The *version* key started at 2, the same version used for the hints. Since Borg has The *version* key started at 2, the same version used for the hints. Since Borg has