Mercurial > hg
comparison mercurial/exchange.py @ 45681:a736ab681b78
errors: stop passing non-strings to Abort's constructor
The next patch will change `Abort`'s constructor and `__bytes__`
functions and they will start assuming that the first argument is the
messages as `bytes`.
Differential Revision: https://phab.mercurial-scm.org/D9178
author | Martin von Zweigbergk <martinvonz@google.com> |
---|---|
date | Thu, 08 Oct 2020 15:35:44 -0700 |
parents | 10284ce3d5ed |
children | 74271829ddc0 |
comparison
equal
deleted
inserted
replaced
45680:bb1a988ef4a5 | 45681:a736ab681b78 |
---|---|
1718 | 1718 |
1719 def prompt(tr): | 1719 def prompt(tr): |
1720 repo = reporef() | 1720 repo = reporef() |
1721 cm = _(b'accept incoming changes (yn)?$$ &Yes $$ &No') | 1721 cm = _(b'accept incoming changes (yn)?$$ &Yes $$ &No') |
1722 if repo.ui.promptchoice(cm): | 1722 if repo.ui.promptchoice(cm): |
1723 raise error.Abort("user aborted") | 1723 raise error.Abort(b"user aborted") |
1724 | 1724 |
1725 tr.addvalidator(b'900-pull-prompt', prompt) | 1725 tr.addvalidator(b'900-pull-prompt', prompt) |
1726 | 1726 |
1727 | 1727 |
1728 def pull( | 1728 def pull( |