diff -r e4803231f538 -r 7e9997041781 hgext/amend.py --- a/hgext/amend.py Sat Sep 14 15:13:16 2019 -0400 +++ b/hgext/amend.py Sat Sep 14 18:44:18 2019 -0400 @@ -16,7 +16,6 @@ from mercurial import ( cmdutil, commands, - error, pycompat, registrar, ) @@ -50,8 +49,8 @@ See :hg:`help commit` for more details. """ opts = pycompat.byteskwargs(opts) - if len(opts['note']) > 255: - raise error.Abort(_("cannot store a note of more than 255 bytes")) + cmdutil.checknotesize(ui, opts) + with repo.wlock(), repo.lock(): if not opts.get('logfile'): opts['message'] = opts.get('message') or repo['.'].description()