def get_registration_detail(self, user_id, hackathon):
    detail = {'hackathon': hackathon.dic(), 'user': self.user_manager.user_display_info(g.user)}
    rel = self.get_registration_by_user_and_hackathon(user_id, hackathon.id)
    if (rel is None):
        return detail
    detail['registration'] = rel.dic()
    try:
        experiment = self.db.find_first_object(Experiment, (Experiment.user_id == user_id), (Experiment.hackathon_id == hackathon.id), Experiment.status.in_([EStatus.STARTING, EStatus.RUNNING]))
        if (experiment is not None):
            detail['experiment'] = experiment.dic()
    except Exception as e:
        self.log.error(e)
    return detail
def get_registration_detail(self, user_id, hackathon):
    detail = {'hackathon': hackathon.dic(), 'user': self.user_manager.user_display_info(g.user)}
    rel = self.get_registration_by_user_and_hackathon(user_id, hackathon.id)
    if (rel is None):
        return detail
    detail['registration'] = rel.dic()
    try:
        experiment = self.db.find_first_object(Experiment, (Experiment.user_id == user_id), (Experiment.hackathon_id == hackathon.id), Experiment.status.in_([EStatus.STARTING, EStatus.RUNNING]))
        if (experiment is not None):
            detail['experiment'] = experiment.dic()
    except Exception as e:
        self.log.error(e)
    return detail