[PATCH] i18n: translate abort messages
Yuya Nishihara
yuya at tcha.org
Wed Jun 15 09:47:16 EDT 2016
On Tue, 14 Jun 2016 18:52:21 +0200, Piotr Listkiewicz wrote:
> > Maybe they should be hard errors?
>
> What do you mean by hard errors, for example they should raise something
> like RuntimeError to indicate to programmer incorrect state?
Yes, I had RuntimeError in mind. indygreg, what do you think?
> 2016-06-14 16:32 GMT+02:00 Yuya Nishihara <yuya at tcha.org>:
> > > +++ b/mercurial/scmutil.py
> > > @@ -461,7 +461,8 @@ class abstractvfs(object):
> > > # have a use case.
> > > vfs = getattr(self, 'vfs', self)
> > > if getattr(vfs, '_backgroundfilecloser', None):
> > > - raise error.Abort('can only have 1 active background file
> > closer')
> > > + raise error.Abort(
> > > + _('can only have 1 active background file closer'))
> >
> > > @@ -209,7 +209,7 @@ def wrapsocket(sock, keyfile, certfile,
> > > to use.
> > > """
> > > if not serverhostname:
> > > - raise error.Abort('serverhostname argument is required')
> > > + raise error.Abort(_('serverhostname argument is required'))
> >
> > Maybe they should be hard errors?
> >
More information about the Mercurial-devel
mailing list