File tree 1 file changed +17
-4
lines changed
1 file changed +17
-4
lines changed Original file line number Diff line number Diff line change 9
9
10
10
@dataclass
11
11
class UpdaterConfig :
12
+ """Used to store Updater configuration.
13
+
14
+ Arguments:
15
+ max_root_rotations: The maximum number of root rotations.
16
+ max_delegations: The maximum number of delegations.
17
+ root_max_length: The maxmimum length of a root metadata file.
18
+ timestamp_max_length: The maximum length of a timestamp metadata file.
19
+ snapshot_max_length: The maximum length of a snapshot metadata file.
20
+ targets_max_length: The maximum length of a targets metadata file.
21
+ prefix_targets_with_hash: When consistent snapshots are used
22
+ (see https://theupdateframework.github.io/specification/latest/#consistent-snapshots), #pylint: disable=line-too-long
23
+ target download URLs are formed by prefixing the filename with a
24
+ hash digest of file content by default. This can be overridden by
25
+ setting prefix_targets_with_hash to False.
26
+
27
+ """
28
+
12
29
max_root_rotations : int = 32
13
30
max_delegations : int = 32
14
31
root_max_length : int = 512000 # bytes
15
32
timestamp_max_length : int = 16384 # bytes
16
33
snapshot_max_length : int = 2000000 # bytes
17
34
targets_max_length : int = 5000000 # bytes
18
- # We need this variable because there are use cases like Warehouse where
19
- # you could use consistent_snapshot, but without adding a hash prefix.
20
- # By default, prefix_targets_with_hash is set to true to use uniquely
21
- # identifiable targets file names for repositories.
22
35
prefix_targets_with_hash : bool = True
You can’t perform that action at this time.
0 commit comments