mercurial/context.py
changeset 18161 5b117f82cbdb
parent 18160 dc526561111c
child 18211 518c1403838f
equal deleted inserted replaced
18160:dc526561111c 18161:5b117f82cbdb
   266 
   266 
   267     def troubled(self):
   267     def troubled(self):
   268         """True if the changeset is either unstable, bumped or divergent"""
   268         """True if the changeset is either unstable, bumped or divergent"""
   269         return self.unstable() or self.bumped() or self.divergent()
   269         return self.unstable() or self.bumped() or self.divergent()
   270 
   270 
       
   271     def troubles(self):
       
   272         """return the list of troubles affecting this changesets.
       
   273 
       
   274         Troubles are returned as strings. possible values are:
       
   275         - unstable,
       
   276         - bumped,
       
   277         - divergent.
       
   278         """
       
   279         troubles = []
       
   280         if self.unstable():
       
   281             troubles.append('unstable')
       
   282         if self.bumped():
       
   283             troubles.append('bumped')
       
   284         if self.divergent():
       
   285             troubles.append('divergent')
       
   286         return troubles
       
   287 
   271     def _fileinfo(self, path):
   288     def _fileinfo(self, path):
   272         if '_manifest' in self.__dict__:
   289         if '_manifest' in self.__dict__:
   273             try:
   290             try:
   274                 return self._manifest[path], self._manifest.flags(path)
   291                 return self._manifest[path], self._manifest.flags(path)
   275             except KeyError:
   292             except KeyError: