pytype/defs.bzl
def pytype_genrunle(
        name,
        pytype_deps,
        pytype_args = [
            "-x=external/",
            # "--config=external/labtools/pytype.cfg",
            # "--config=pytype.cfg",
            " .",
        ],
        **kwargs):
    """A macro that runs pytest tests by using a test runner.

    Args:
        name: A unique name for this rule.
        pytype_deps: a list of pytype-only deps
        pytype_args: a list of arguments passed to pytype
        **kwargs: are passed to py_test, with srcs and deps attrs modified
    """

    kwargs.pop("main", [])
    deps = kwargs.pop("deps", []) + [clean_dep("//pytype:pytype_helper")]
    srcs = kwargs.pop("srcs", []) + [clean_dep("//pytype:pytype_helper")]

    args = kwargs.pop("args", [])
    args = pytype_args

    # add pytype tag
    tags = kwargs.pop("tags", []) + ["pytype"]

    # add pytype deps
    deps += pytype_deps

    py_test(
        name = "%s__pytype" % name,
        srcs = srcs,
        main = "pytype_helper.py",
        python_version = "PY3",
        deps = deps,
        args = args,
        tags = tags,
        **kwargs
    )
A macro that runs pytest tests by using a test runner.

    Args:
        name: A unique name for this rule.
        pytype_deps: a list of pytype-only deps
        pytype_args: a list of arguments passed to pytype
        **kwargs: are passed to py_test, with srcs and deps attrs modified
    
A macro that runs pytest tests by using a test runner.
A macro that runs pytest tests by using a test runner .
def pytype_genrunle(
        name,
        pytype_deps,
        pytype_args = [
            "-x=external/",
            " .",
        ],
        **kwargs):
    kwargs.pop("main", [])
    deps = kwargs.pop("deps", []) + [clean_dep("//pytype:pytype_helper")]
    srcs = kwargs.pop("srcs", []) + [clean_dep("//pytype:pytype_helper")]
    args = kwargs.pop("args", [])
    args = pytype_args
    tags = kwargs.pop("tags", []) + ["pytype"]
    deps += pytype_deps
    py_test(
        name = "%s__pytype" % name,
        srcs = srcs,
        main = "pytype_helper.py",
        python_version = "PY3",
        deps = deps,
        args = args,
        tags = tags,
        **kwargs
    )
def pytype_genrunle ( name , pytype_deps , pytype_args = [ "-x=external/" , " ." , ] , ** kwargs ) : kwargs . pop ( "main" , [ ] ) deps = kwargs . pop ( "deps" , [ ] ) + [ clean_dep ( "//pytype:pytype_helper" ) ] srcs = kwargs . pop ( "srcs" , [ ] ) + [ clean_dep ( "//pytype:pytype_helper" ) ] args = kwargs . pop ( "args" , [ ] ) args = pytype_args tags = kwargs . pop ( "tags" , [ ] ) + [ "pytype" ] deps += pytype_deps py_test ( name = "%s__pytype" % name , srcs = srcs , main = "pytype_helper.py" , python_version = "PY3" , deps = deps , args = args , tags = tags , ** kwargs )
A macro that runs pytest tests by using a test runner.
A macro that runs pytest tests by using a test runner .
# "--config=external/labtools/pytype.cfg", # "--config=pytype.cfg", """A macro that runs pytest tests by using a test runner.

    Args:
        name: A unique name for this rule.
        pytype_deps: a list of pytype-only deps
        pytype_args: a list of arguments passed to pytype
        **kwargs: are passed to py_test, with srcs and deps attrs modified
    """ # add pytype tag # add pytype deps
name
A unique name for this rule.
A unique name for this rule .
pytype_deps
a list of pytype-only deps
a list of pytype - only deps
pytype_args
a list of arguments passed to pytype
a list of arguments passed to pytype
**kwargs
None