def raise_dependencies_check(self, ref_check, hosts, services, timeperiods, macromodulations,
                                 checkmodulations, checks):
        # pylint: disable=too-many-locals, too-many-nested-blocks
        """Get checks that we depend on if EVERY following conditions is met::

        * timeperiod is valid
        * dep.last_state_update < now - cls.cached_check_horizon (check of dependency is "old")

        :param ref_check: Check we want to get dependency from
        :type ref_check: alignak.check.Check
        :param hosts: hosts objects, used for almost every operation
        :type hosts: alignak.objects.host.Hosts
        :param services: services objects, used for almost every operation
        :type services: alignak.objects.service.Services
        :param timeperiods: Timeperiods objects, used for all kind of timeperiod (notif, check)
        :type timeperiods: alignak.objects.timeperiod.Timeperiods
        :param macromodulations: Macro modulations objects, used in commands (notif, check)
        :type macromodulations: alignak.objects.macromodulation.Macromodulations
        :param checkmodulations: Checkmodulations objects, used to change check command if necessary
        :type checkmodulations: alignak.objects.checkmodulation.Checkmodulations
        :param checks: checks dict, used to get checks_in_progress for the object
        :type checks: dict
        :return: check created and check in_checking
        :rtype: dict
        """
        now = time.time()
        cls = self.__class__
        new_checks = []
        checking_checks = []
        for (dep_id, _, timeperiod_id, _) in self.act_depend_of:
            if dep_id in hosts:
                dep_item = hosts[dep_id]
            else:
                dep_item = services[dep_id]
            timeperiod = timeperiods[timeperiod_id]
            # If the dep_item timeperiod is not valid, do not raise the dep,
            # None=everytime
            if timeperiod is None or timeperiod.is_time_valid(now):
                # if the update is 'fresh', do not raise dep,
                # cached_check_horizon = cached_service_check_horizon for service
                if dep_item.last_state_update < now - cls.cached_check_horizon:
                    # Do not launch the check if it depends on a passive check of if a check
                    # is yet planned
                    if dep_item.active_checks_enabled:
                        if not dep_item.in_checking:
                            newchk = dep_item.launch_check(now, hosts, services, timeperiods,
                                                           macromodulations, checkmodulations,
                                                           checks, ref_check, dependent=True)
                            if newchk is not None:
                                new_checks.append(newchk)
                        else:
                            if dep_item.checks_in_progress:
                                check_uuid = dep_item.checks_in_progress[0]
                                checks[check_uuid].depend_on_me.append(ref_check)
                                checking_checks.append(check_uuid)
        return {'new': new_checks, 'checking': checking_checks}
Get checks that we depend on if EVERY following conditions is met::

        * timeperiod is valid
        * dep.last_state_update < now - cls.cached_check_horizon (check of dependency is "old")

        :param ref_check: Check we want to get dependency from
        :type ref_check: alignak.check.Check
        :param hosts: hosts objects, used for almost every operation
        :type hosts: alignak.objects.host.Hosts
        :param services: services objects, used for almost every operation
        :type services: alignak.objects.service.Services
        :param timeperiods: Timeperiods objects, used for all kind of timeperiod (notif, check)
        :type timeperiods: alignak.objects.timeperiod.Timeperiods
        :param macromodulations: Macro modulations objects, used in commands (notif, check)
        :type macromodulations: alignak.objects.macromodulation.Macromodulations
        :param checkmodulations: Checkmodulations objects, used to change check command if necessary
        :type checkmodulations: alignak.objects.checkmodulation.Checkmodulations
        :param checks: checks dict, used to get checks_in_progress for the object
        :type checks: dict
        :return: check created and check in_checking
        :rtype: dict