rust-cpython: do not convert warning pattern to utf-8 bytes
On Unix, both Rust Path and Mercurial expect a locale-dependent bytes,
and we don't support Windows yet.
Differential Revision: https://phab.mercurial-scm.org/D7614
rust-cpython: import utils::files::* function at module level
IIRC, it's common in Rust to call functions with the module prefix.
Differential Revision: https://phab.mercurial-scm.org/D7613
py3: send bytes from Rust-created warning patterns
Python code expects bytes in both Python 2 and Python 3, so we should send
bytes.
Differential Revision: https://phab.mercurial-scm.org/D7612
py3: pass bytes to `configint` and `configbool`
Both functions require bytes, even in Python 3.
Differential Revision: https://phab.mercurial-scm.org/D7611
rust-threads: force Rayon to respect the worker count in config
As per the inline comment, this is a workaround because Rust code does not yet
know how to read config files.
Differential Revision: https://phab.mercurial-scm.org/D7610
rust-dirs: handle forgotten `Result`s
In
1fe2e574616e I introduced a temporary bugfix to align Rust code with a new
behavior from C/Python and forgot about a few `Result`s (cargo's compiler cache
does not re-emit warnings on cached modules). This fixes it.
For the record, I am still unsure that this behavior change is a good idea.
Note: I was already quite unhappy with the setters and getters for the
`DirstateMap` and, indirectly, `Dirs`, and this only further reinforces my
feelings. I hope we can one day fix that situation at the type level; Georges
Racinet and I were just talking about devising a POC for using the builder
pattern in the context of FFI with Python, we'll see what comes out of it.
Differential Revision: https://phab.mercurial-scm.org/D7609
status: outputting structured unfinished-operation information
This adds a new item in the json/template output for morestatus and added item
types to all entries.
Differential Revision: https://phab.mercurial-scm.org/D7595