With such a timestamp it is no longer possible to query the "created" field on tickets. The API will return the error "must not be null". Example query:
query {
trackerByOwner(owner: "~emersion", tracker: "hut") {
tickets {
results {
id
created
}
}
}
}
So, for all I can tell, the culprit here is (at least) this ticket: https://todo.sr.ht/~emersion/hut/17 (note the "Submitted 2,022 years ago").
Wouldn't it maybe make more sense to either purge tickets with such a timestamp from the database or set a different one? Fixing this would likely mean fighting generated code, and I don't think this can ever happen again once we fixed it, right?
With the current GraphQL implementation users can always generate such a ticket by setting the timestamp to the zero value (default in go). So there needs to be at least a validation that would forbid such tickets from being created ever again.
We should fix the bug and then remove or correct any invalid records.
Conrad Hoffmann referenced this ticket in commit c28e447.