File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -63,6 +63,8 @@ def validate_digits_or_empty(value):
6363 return True
6464 try :
6565 int (value )
66+ if int (value ) != - 1 and int (value ) <= 0 :
67+ return "Input must be a positive number"
6668 return True
6769 except ValueError :
6870 return "Input must be a number"
@@ -121,6 +123,8 @@ def run_cli():
121123 get_archive_ttl_message (temp_answers ),
122124 validate = validate_digits_or_empty
123125 ).unsafe_ask ()
126+ if not archive_ttl and 'archive-ttl-default' in temp_answers :
127+ archive_ttl = temp_answers ['archive-ttl-default' ]
124128
125129 dump = None
126130 if not archive_blocks :
@@ -159,7 +163,7 @@ def run_install(answers: dict) -> list:
159163 mode = answers ["mode" ]
160164 network = answers ["network" ].lower ()
161165 config = answers ["config" ]
162- archive_ttl = answers ["archive-ttl" ] or answers . get ( "archive-ttl-default" )
166+ archive_ttl = answers ["archive-ttl" ]
163167 add_shard = answers ["add-shard" ]
164168 validator_mode = answers ["validator-mode" ]
165169 archive_blocks = answers ["archive-blocks" ]
You can’t perform that action at this time.
0 commit comments