parent
3163bca99b
commit
b66f852256
|
@ -416,9 +416,16 @@ async def get_data(
|
||||||
for launch in rockets:
|
for launch in rockets:
|
||||||
dt = None
|
dt = None
|
||||||
|
|
||||||
if launch["net_precision"] == "Day":
|
net_precision = launch["net_precision"]
|
||||||
|
skip = {"Year", "Month", "Quarter", "Fiscal Year"}
|
||||||
|
if net_precision == "Day":
|
||||||
dt = datetime.strptime(launch["net"], "%Y-%m-%dT%H:%M:%SZ").date()
|
dt = datetime.strptime(launch["net"], "%Y-%m-%dT%H:%M:%SZ").date()
|
||||||
elif launch["t0_time"]:
|
elif (
|
||||||
|
net_precision
|
||||||
|
and net_precision not in skip
|
||||||
|
and "Year" not in net_precision
|
||||||
|
and launch["t0_time"]
|
||||||
|
):
|
||||||
dt = pytz.utc.localize(
|
dt = pytz.utc.localize(
|
||||||
datetime.strptime(launch["net"], "%Y-%m-%dT%H:%M:%SZ")
|
datetime.strptime(launch["net"], "%Y-%m-%dT%H:%M:%SZ")
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in a new issue