'Determine whether or not this object should be skipped.
If this model instance is a parent of a single subclassed
instance, skip it. The subclassed instance will create this
parent instance for us.
TODO: Allow the user to force its creation?'

def skip(self):

    if (self.skip_me is not None):
        return self.skip_me
    def get_skip_version():
        "    Return    which    version    of    the    skip    code    should    be    run\n\n                                                                Django's    deletion    code    was    refactored    in    r14507    which\n                                                                was    just    two    days    before    1.3    alpha    1    (r14519)\n                                                "
        if (not hasattr(self, '_SKIP_VERSION')):
            version = django.VERSION
            self._SKIP_VERSION = ((((version[0] > 1) or ((version[0] == 1) and ((version[1] >= 4) or ((version[1] == 3) and (not ((version[3] == 'alpha') and (version[1] == 0))))))) and 2) or 1)
        return self._SKIP_VERSION
    if (get_skip_version() == 1):
        try:
            from django.db.models.query import CollectedObjects
            sub_objects = CollectedObjects()
        except ImportError:
            sub_objects = {}
        self.instance._collect_sub_objects(sub_objects)
        sub_objects = sub_objects.keys()
    elif (get_skip_version() == 2):
        from django.db.models.deletion import Collector
        from django.db import router
        cls = self.instance.__class__
        using = router.db_for_write(cls, instance=self.instance)
        collector = Collector(using=using)
        collector.collect([self.instance], collect_related=False)
        sub_objects = sum([list(i) for i in collector.data.values()], [])
        if hasattr(collector, 'batches'):
            for batch in collector.batches.values():
                sub_objects += sum([list(i) for i in batch.values()], [])
    sub_objects_parents = [so._meta.parents for so in sub_objects]
    if ([(self.model in p) for p in sub_objects_parents].count(True) == 1):
        pk_name = self.instance._meta.pk.name
        key = ('%s_%s' % (self.model.__name__, getattr(self.instance, pk_name)))
        self.context[key] = None
        self.skip_me = True
    else:
        self.skip_me = False
    return self.skip_me
