Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(5)  |  Call(0)  |  Derive(0)  |  Import(5)

src/c/a/catkin_lint-1.3.4/src/catkin_lint/main.py   catkin_lint(Download)
import importlib
from . import __version__ as catkin_lint_version
from .linter import CatkinEnvironment, CMakeLinter, ERROR, WARNING, NOTICE
from .output import TextOutput, ExplainedTextOutput, XmlOutput
 
                sys.stderr.write("catkin_lint: cannot lint %s: %s\n" % (manifest.name, str(err)))
                if args.debug: raise
        suppressed = { ERROR: 0, WARNING: 0, NOTICE: 0 }
        problems = 0
        exit_code = 0
        diagnostic_label = { ERROR : "error", WARNING : "warning", NOTICE : "notice" }
        if not args.quiet:
            sys.stderr.write ("catkin_lint: checked %d packages and found %d problems\n" % (len(pkgs_to_check), problems))
            for level in [ ERROR, WARNING, NOTICE ]:
                if suppressed[level] > 0:
                    sys.stderr.write ("catkin_lint: %d %ss have been ignored. Use -W%d to see them\n" % (suppressed[level], diagnostic_label[level], level))

src/c/a/catkin_lint-1.3.4/src/catkin_lint/checks/build.py   catkin_lint(Download)
import os
import re
from ..linter import ERROR, WARNING, NOTICE
from ..cmake import argparse as cmake_argparse
from ..util import word_split, iteritems
            info.report (ERROR, "EXTERNAL_LINK_DIRECTORY")
        else:
            info.report (WARNING, "LINK_DIRECTORY")
 
    linter.add_command_hook("link_directories", on_link_directories)
            info.report(ERROR, "ORDER_VIOLATION", first_cmd="catkin_package", second_cmd=cmd)
        if not opts["REQUIRED"]:
            info.report(WARNING, "MISSING_REQUIRED", pkg="catkin")
            info.required_packages.add("catkin")
        for pkg in opts["COMPONENTS"]:
        for pkg in (info.find_packages & info.build_dep & info.run_dep) - info.export_packages:
            if re.search(r"_(msg|message)s?(_|$)", pkg) and info.env.is_catkin_pkg(pkg):
                info.report (WARNING, "SUGGEST_CATKIN_DEPEND", pkg=pkg)
        if info.export_includes and info.libraries and not info.export_libs:
            info.report(WARNING, "MISSING_EXPORT_LIB")

src/c/a/catkin_lint-1.3.4/src/catkin_lint/checks/misc.py   catkin_lint(Download)
"""
import re
from ..linter import ERROR, WARNING, NOTICE
from ..cmake import argparse as cmake_argparse
 
                info.report(ERROR, "CRITICAL_VAR_OVERWRITE", var=args[0])
            else:
                info.report(WARNING, "CRITICAL_VAR_APPEND", var=args[0])
    def on_list(info, cmd, args):
        if args[0] in ["LENGTH","GET","FIND"]: return
        if args[1] in immutable_vars:
            info.report(ERROR, "IMMUTABLE_VAR", var=args[1])
        if args[1] in critical_vars:
            if args[0] in ["APPEND","INSERT"]:
                info.report(WARNING, "CRITICAL_VAR_APPEND", var=args[1])

src/c/a/catkin_lint-1.3.4/src/catkin_lint/output.py   catkin_lint(Download)
import sys
import textwrap
from .linter import ERROR, WARNING, NOTICE
from . import __version__
 
class TextOutput(object):
 
    diagnostic_label = { ERROR : "error", WARNING : "warning", NOTICE : "notice" }
class XmlOutput(object):
 
    tag_label = { ERROR : "error", WARNING : "warning", NOTICE : "notice" }
 
    def _quote(self, s):

src/c/a/catkin_lint-1.3.4/src/catkin_lint/checks/fkie.py   catkin_lint(Download)
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
"""
from ..linter import ERROR, WARNING
from ..cmake import argparse as cmake_argparse
from .build import depends as build_depends
    def on_fkie_find_package(info, cmd, args):
        opts, args = cmake_argparse(args, { "REQUIRED": "-", "COMPONENTS": "*" })
        info.report(ERROR if args[0] == "catkin" else WARNING, "DEPRECATED_ROSBUILD", cmd=cmd)
        if not "project" in info.commands:
            info.report(ERROR, "ORDER_VIOLATION", first_cmd=cmd, second_cmd="project")