@raise_if_unsaved
    def get_previous_sibling(self, *filter_args, **filter_kwargs):
        opts = self._mptt_meta
        qs = self._tree_manager.filter(*filter_args, **filter_kwargs)
        if self.is_root_node():
            qs = self._tree_manager._mptt_filter(
                qs,
                parent=None,
                tree_id__lt=self._mpttfield('tree_id'),
            )
            qs = qs.order_by('-' + opts.tree_id_attr)
        else:
            qs = self._tree_manager._mptt_filter(
                qs,
                parent__pk=getattr(self, opts.parent_attr + '_id'),
                right__lt=self._mpttfield('left'),
            )
            qs = qs.order_by('-' + opts.right_attr)

        siblings = qs[:1]
        return siblings and siblings[0] or None
Parse a time stamp in the "year-month-day hour-minute" format.
dataset/ETHPy150Open django-mptt/django-mptt/mptt/models.py/MPTTModel.get_previous_sibling--crossover with--dataset/ETHPy150Open sosy-lab/benchexec/benchexec/benchexec.py/parse_time_arg