How to use the retype.retype_hgext.apply_job_security function in retype

To help you get started, we’ve selected a few retype examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github ambv / retype / src / retype / __init__.py View on Github external
def lib2to3_unparse(node, *, hg=False):
    """Given a lib2to3 node, return its string representation."""
    code = str(node)
    if hg:
        from retype.retype_hgext import apply_job_security

        code = apply_job_security(code)
    return code