def format_context(text, data):
    """replace custom templating by something compliant with python format function"""
    text = text.replace('{', '{{').replace('}', '}}')
    text = text.replace('#!-', '{').replace('-!#', '}')
    return text.format(**data)
