docs: def get_patches_base(self, expand_macros=False):
          """Return a tuple (version, number_of_commits) that are parsed
          from the patches_base in the specfile.
          """
          match = re.search(r'(?<=patches_base=)[\w.+?%{}]+', self.txt)
          if not match:
              return None, 0
  
          patches_base = match.group()
          if expand_macros and has_macros(patches_base):
              # don't parse using rpm unless required
              patches_base = self.expand_macro(patches_base)
          patches_base_ref, _, n_commits = patches_base.partition('+')
  
          try:
              n_commits = int(n_commits)
          except ValueError:
              n_commits = 0
          return patches_base_ref, n_commits