Segfault in TM

(I'm sending this as email because the TM tracker does not work for me:
the project has no components, which prevents filing an issue.)

Ahir consistently ran into segmentation faults with his workload. We
debugged the issue and found the culprit: In, a call
std::vector<T>::front() violates the precondition

    ! std::vector<T>::empty()
and thus causes UB. I fixed this here:
It's a one-line fix and ready to merge.


I just made the component field optional for TM tickets which should fix it, let me know if not.

- Jon