Data and Knowledge Systems · Principal
The incident happened at 1:30 AM twice. Which event did the AI report use?
The question
Interview question
An operations feed stores an incident as `2026-11-01 01:30` in New York, with no UTC offset. On the night clocks turn back, two different instants have that local time. A reporting agent joins incidents to a deployment timeline and confidently says the incident preceded the deploy. Is that conclusion supported?
Take a few minutes to form your approach. Then open a worked answer and compare the decisions.
Reveal a worked answer
No. New York observes 1:30 once in daylight time and again in standard time on that date. Those are an hour apart in UTC. A local wall-clock string plus an IANA zone name still does not select which occurrence was meant. Python's time-zone documentation uses a fold distinction for these two offsets. The iCalendar specification defines a first-occurrence convention for ambiguous local times in its own format. That convention is not a license to impose the first occurrence on an unrelated incident feed without a contract.
I would trace the raw source record and its schema. Does it have an offset, a UTC timestamp, an event sequence, a device clock, or a monotonic ID that can resolve the ambiguity? If so, preserve the original local representation and the chosen instant, plus the rule used to convert. If not, mark the event time ambiguous and avoid asserting a before-or-after relationship with a deployment inside that hour. An ingest timestamp only says when the system saw the record. It cannot necessarily reconstruct when the incident occurred.
At ingestion, require an instant or a local time plus zone and disambiguation for sources that cross daylight-saving changes. For legacy data, classify ambiguous and nonexistent local times rather than silently parsing them to a default offset. Test both occurrences of 1:30, a spring-forward time that never exists, and records from regions without such transitions. If the product must display local time, convert a stored instant to the viewer's zone at read time and retain the original source timestamp for audit.
The incident happened last Sunday. Why did the AI report count it this week? asks whether a late Sunday incident should be counted by event time or ingestion time. Here the event time itself is not a unique instant. That difference matters before the AI system can make any chronology claim.
Continue reading
Related questions
Read beyond the question
Explore more data and knowledge systems
Follow another question in this area, or search the complete Question Library.
Browse this area →Browse Question Library →