File tree Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Original file line number Diff line number Diff line change @@ -58,7 +58,7 @@ class LogCheckpoint(BaseModel):
58
58
- an origin, e.g. "rekor.sigstage.dev - 8050909264565447525"
59
59
- the size of the log,
60
60
- the hash of the log,
61
- - and any ancillary contants, e.g. "Timestamp: 1679349379012118479"
61
+ - and any optional ancillary contants, e.g. "Timestamp: 1679349379012118479"
62
62
63
63
See: <https://github.com/transparency-dev/formats/blob/main/log/README.md>
64
64
"""
@@ -75,7 +75,7 @@ def from_text(cls, text: str) -> LogCheckpoint:
75
75
"""
76
76
77
77
lines = text .strip ().split ("\n " )
78
- if len (lines ) < 4 :
78
+ if len (lines ) < 3 :
79
79
raise CheckpointError ("Malformed LogCheckpoint: too few items in header!" )
80
80
81
81
origin = lines [0 ]
@@ -99,12 +99,7 @@ def to_text(self) -> str:
99
99
See class definition for a prose description of the format.
100
100
"""
101
101
return "\n " .join (
102
- [
103
- self .origin ,
104
- str (self .log_size ),
105
- self .log_hash ,
106
- ]
107
- + self .other_content
102
+ [self .origin , str (self .log_size ), self .log_hash , * self .other_content ]
108
103
)
109
104
110
105
You can’t perform that action at this time.
0 commit comments