mercurial/upgrade.py
changeset 43117 8ff1ecfadcd1
parent 43089 c59eb1560c44
child 43134 75ad8af9c95e
equal deleted inserted replaced
43116:defabf63e969 43117:8ff1ecfadcd1
   407         b'Compresion algorithm used to compress data. '
   407         b'Compresion algorithm used to compress data. '
   408         b'Some engine are faster than other'
   408         b'Some engine are faster than other'
   409     )
   409     )
   410 
   410 
   411     upgrademessage = _(
   411     upgrademessage = _(
   412         b'revlog content will be recompressed with the new ' b'algorithm.'
   412         b'revlog content will be recompressed with the new algorithm.'
   413     )
   413     )
   414 
   414 
   415     @classmethod
   415     @classmethod
   416     def fromrepo(cls, repo):
   416     def fromrepo(cls, repo):
   417         # we allow multiple compression engine requirement to co-exist because
   417         # we allow multiple compression engine requirement to co-exist because
  1104 
  1104 
  1105     # Ensure the repository can be upgraded.
  1105     # Ensure the repository can be upgraded.
  1106     missingreqs = requiredsourcerequirements(repo) - repo.requirements
  1106     missingreqs = requiredsourcerequirements(repo) - repo.requirements
  1107     if missingreqs:
  1107     if missingreqs:
  1108         raise error.Abort(
  1108         raise error.Abort(
  1109             _(b'cannot upgrade repository; requirement ' b'missing: %s')
  1109             _(b'cannot upgrade repository; requirement missing: %s')
  1110             % _(b', ').join(sorted(missingreqs))
  1110             % _(b', ').join(sorted(missingreqs))
  1111         )
  1111         )
  1112 
  1112 
  1113     blockedreqs = blocksourcerequirements(repo) & repo.requirements
  1113     blockedreqs = blocksourcerequirements(repo) & repo.requirements
  1114     if blockedreqs:
  1114     if blockedreqs:
  1171 
  1171 
  1172     if optimize:  # anything left is unknown
  1172     if optimize:  # anything left is unknown
  1173         raise error.Abort(
  1173         raise error.Abort(
  1174             _(b'unknown optimization action requested: %s')
  1174             _(b'unknown optimization action requested: %s')
  1175             % b', '.join(sorted(optimize)),
  1175             % b', '.join(sorted(optimize)),
  1176             hint=_(b'run without arguments to see valid ' b'optimizations'),
  1176             hint=_(b'run without arguments to see valid optimizations'),
  1177         )
  1177         )
  1178 
  1178 
  1179     deficiencies = finddeficiencies(repo)
  1179     deficiencies = finddeficiencies(repo)
  1180     actions = determineactions(repo, deficiencies, repo.requirements, newreqs)
  1180     actions = determineactions(repo, deficiencies, repo.requirements, newreqs)
  1181     actions.extend(
  1181     actions.extend(