Skip to content

Commit 3932968

Browse files
authored
Use a default timestamp in create_image.py (#79)
If no timestamp is provided 'None' will be used which will break OTA on the build farm. This happens doing a local build if the user doesn't specify a timestamp explicitly.
1 parent eeb00a8 commit 3932968

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

tailor_image/create_image.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
import sys
66

77
from typing import Any, List
8+
from datetime import datetime
89

910
import argparse
1011
import click
@@ -264,7 +265,9 @@ def main():
264265
parser.add_argument('--publish', action='store_true')
265266
parser.add_argument('--docker-registry', type=str)
266267
parser.add_argument('--rosdistro-path', type=pathlib.Path)
267-
parser.add_argument('--timestamp', type=str)
268+
parser.add_argument(
269+
'--timestamp', type=str, default=datetime.now().strftime("%Y%m%d.%H%M%S")
270+
)
268271

269272
args = parser.parse_args()
270273

0 commit comments

Comments
 (0)