Patchwork D7453: py3: pass bytes to `configint` and `configbool`

login
register
mail settings
Submitter phabricator
Date Nov. 19, 2019, 3:49 a.m.
Message ID <7a124eb9207b19c9dad37fcda674e1f1@localhost.localdomain>
Download mbox | patch
Permalink /patch/43339/
State Not Applicable
Headers show

Comments

phabricator - Nov. 19, 2019, 3:49 a.m.
Closed by commit rHG794426e96970: py3: pass bytes to `configint` and `configbool` (authored by Alphare).
This revision was automatically updated to reflect the committed changes.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D7453?vs=18209&id=18219

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D7453/new/

REVISION DETAIL
  https://phab.mercurial-scm.org/D7453

AFFECTED FILES
  mercurial/dirstate.py

CHANGE DETAILS




To: Alphare, #hg-reviewers, indygreg
Cc: mercurial-devel

Patch

diff --git a/mercurial/dirstate.py b/mercurial/dirstate.py
--- a/mercurial/dirstate.py
+++ b/mercurial/dirstate.py
@@ -1112,13 +1112,13 @@ 
             # Force Rayon (Rust parallelism library) to respect the number of
             # workers. This is a temporary workaround until Rust code knows
             # how to read the config file.
-            numcpus = self._ui.configint("worker", "numcpus")
+            numcpus = self._ui.configint(b"worker", b"numcpus")
             if numcpus is not None:
                 encoding.environ.setdefault(
                     b'RAYON_NUM_THREADS', b'%d' % numcpus
                 )
 
-            workers_enabled = self._ui.configbool("worker", "enabled", True)
+            workers_enabled = self._ui.configbool(b"worker", b"enabled", True)
             if not workers_enabled:
                 encoding.environ[b"RAYON_NUM_THREADS"] = b"1"