def __init__(self, pml_path, worktree=None):
        if not os.path.exists(pml_path):
            raise qisys.error.Error("%s does not exist" % pml_path)
        self.pml_path = pml_path
        self.base_dir = os.path.dirname(self.pml_path)
        self.manifest_xml = os.path.join(self.base_dir, "manifest.xml")
        if not os.path.exists(self.manifest_xml):
            raise qisys.error.Error(self.manifest_xml % "%s does not exist")
        self.pkg_name = pkg_name(self.manifest_xml)


        self.worktree = worktree

        if self.worktree:
            self.build_worktree = qibuild.worktree.BuildWorkTree(self.worktree)
            self.cmake_builder = qibuild.cmake_builder.CMakeBuilder(self.build_worktree)

            self.python_worktree = qipy.worktree.PythonWorkTree(self.worktree)
            self.python_builder = qipy.python_builder.PythonBuilder(
                self.python_worktree,
                build_worktree=self.build_worktree)

            self.linguist_worktree = qilinguist.worktree.LinguistWorkTree(self.worktree)
            self.linguist_builder = qilinguist.builder.QiLinguistBuilder()

            self.builders = [self.cmake_builder, self.python_builder, self.linguist_builder]
        else:
            self.cmake_builder = None
            self.build_worktree = None
            self.python_builder = None
            self.python_worktree = None
            self.linguist_builder = None
            self.linguist_worktree = None
            self.builders = list()

        # Hack: we don't want to generate symbols from the staged dir
        # unless we have at least one qibuild project
        self.build_project = None

        self._stage_path = None
        self.pml_extra_files = list()

        self.load_pml(pml_path)

        # read the manifest and validate it
        self.validator = qipkg.manifest.Validator(self.manifest_xml)
        self.validator.print_errors()
        self.validator.print_warnings()
dataset/ETHPy150Open aldebaran/qibuild/python/qipkg/builder.py/PMLBuilder.__init__/swapped operands of `%`