- Feb 21, 2025
-
-
Mitchell Kember authored
This means that lints configured in rust/Cargo.toml will apply to all crates within the workspace. Currently there are none but I plan to add some.
-
- Jan 07, 2025
-
-
Raphaël Gomès authored
These dependencies are not needed anymore, so trim them down.
-
- Dec 05, 2024
-
-
Georges Racinet authored
The crate name is actually `rusthg`. This has the side effect of running the doctest of the `py_shared_iterator` macro which was really inconsistent, and after basic fixes, exposed that the macro itself was poorly scoped.
-
- Nov 29, 2024
-
-
Georges Racinet authored
The dependency to `sys-python3` stayed at version 0.7.1 when `cpython` got bumped to 0.7.2 for Python 3.12 support. In pratice, this does not change much because Cargo rules imply that this means ">= 0.7.1, <0.8.0". Still it did not feel right, either `cpython` enforces a stricter version and this specification is not needed at all, or it meant that it was still possible to install the older version of `sys-python3`.
-
- Nov 04, 2024
-
-
Raphaël Gomès authored
Aside from being more up-to-date in general, this makes its own dependency on the unmaintained and now useless `atty` disappear.
-
- Jun 19, 2024
-
-
Raphaël Gomès authored
The performance of this has been looked at for quite some time, and some workflows are actually quite a bit faster than with the Python + C code. However, we are still (up to 20%) slower in some crucial places like cloning certain repos, log, cat, which makes this an incomplete rewrite. This is mostly due to the high amount of overhead in Python <-> Rust FFI, especially around the VFS code. A future patch series will rewrite the VFS code in pure Rust, which should hopefully get us up to par with current perfomance, if not better in all important cases. This is a "save state" of sorts, as this is a ton of code, and I don't want to pile up even more things in a single review. Continuing to try to match the current performance will take an extremely long time, if it's not impossible, without the aforementioned VFS work.
-
- Sep 17, 2024
-
-
Pierre-Yves David authored
This version supports Python 3.12 while 0.7.1 did not.
-
- Nov 14, 2022
-
-
Raphaël Gomès authored
`hg-cpython` has no BC breaking dependencies, we can group them all in this changeset.
-
Raphaël Gomès authored
We've changed our minimum Rust version to 1.61.0 in the previous patch, and edition 2021 predates that version.
-
- Mar 09, 2022
-
-
Raphaël Gomès authored
This upgrades all dependencies to their latest version. This is routinely done to keep-up. Differential Revision: https://phab.mercurial-scm.org/D12359
-
- Mar 03, 2022
-
-
Simon Sapin authored
Note: `cpython/python3-sys` is a default feature. Differential Revision: https://phab.mercurial-scm.org/D12316
-
- Mar 02, 2022
-
-
Augie Fackler authored
Differential Revision: https://phab.mercurial-scm.org/D12283
-
- Dec 10, 2021
-
-
Euxane TRAN-GIRARD authored
Preparing the integration of the vcsgraph library, which will provide generic algorithms for computations on version control graphs. Differential Revision: https://phab.mercurial-scm.org/D11945
-
- Oct 12, 2021
-
-
Simon Sapin authored
This notably brings support for Python 3.10, and includes the panic message when propagating a Rust panic as a Python exception. https://github.com/dgrunwald/rust-cpython/blob/master/CHANGELOG.md#070---2021-10-09 Differential Revision: https://phab.mercurial-scm.org/D11630
-
Simon Sapin authored
Previously we stored the entire value from `stat_result.st_mode`, like dirstate-v1 does. However only the executable permission and type of file (only symbolic links and normal files are supported) are relevant to Mecurial. So replace this field with two bits in the existing bitfield byte. For now the unused space is left as padding, as it will be used for something else soon. Differential Revision: https://phab.mercurial-scm.org/D11635
-
- Oct 08, 2021
-
-
Simon Sapin authored
This default is used when running `cargo` manually such as for `cargo test`. `setup.py` and `Makefile` both configure the Python major version explicitly. Differential Revision: https://phab.mercurial-scm.org/D11618
-
- Sep 09, 2021
-
-
Simon Sapin authored
This will enable using it in rhg too. The `OwningDirstateMap::new_empty` constructor is generic and accepts a value of any type that gives acces to a bytes buffer. That buffer must stay valid as long as the value hasn’t been dropped, and must keep its memory address even if the value is moved. The `StableDeref` marker trait encodes those constraints. Previously no trait was needed because the value was always of type `PyBytes` which we know satisfies those constraints. The buffer type is ereased in the struct itself through boxing and dynamic dispatch, in order to simplify other signatures that mention `OwningDirstateMap`. Differential Revision: https://phab.mercurial-scm.org/D11396
-
- Jul 04, 2021
-
-
Pierre-Yves David authored
That function as a nice `is_none` method on `PyObject` that we will put to use. Differential Revision: https://phab.mercurial-scm.org/D10962
-
- Apr 08, 2021
-
-
Simon Sapin authored
This code has compiler errors since it is not built on CI and nobody has been working on it for some time. We (Octobus) are still pursuing status optimizations based on a tree data structure for the dirstate, but upcoming patches will use a run-time opt-in instead of compile-time, so that at least corresponding Rust code keeps compiling when other changes are made. Differential Revision: https://phab.mercurial-scm.org/D10329
-
- Apr 05, 2021
-
-
Pierre-Yves David authored
we need a newer version to define "property" on Rust defined object. Differential Revision: https://phab.mercurial-scm.org/D10308
-
- Jan 06, 2021
-
-
Simon Sapin authored
… that runs in parallel with the parent thread fetching data. This can be disabled through a new config. CLI example: hg --config=devel.copy-tracing.multi-thread=no For now both threads use the GIL, later commits will reduce this. Differential Revision: https://phab.mercurial-scm.org/D9684
-
- Sep 30, 2020
-
-
Raphaël Gomès authored
This feature gates (at compile-time) the use of the newly-added dirstate tree. The motivation for this is that the dirstate tree is currently *very* slow; replacing the current hashmap-based dirstate is not a viable solution in terms of performance... and why would you be using the Rust implementation if not for performance? The feature will also help reviewers better understand the differences that will slowly appear as the dirstate tree gets better. Differential Revision: https://phab.mercurial-scm.org/D9132
-
- Sep 06, 2020
-
-
Raphaël Gomès authored
`simple_logger` is just too simple. `env_logger` supports logging to `stderr`, and logging filtering, for example, which are becoming necessary now. The project is nicely active. Differential Revision: https://phab.mercurial-scm.org/D8990
-
- May 29, 2020
-
-
Raphaël Gomès authored
With the performance issues with `regex` figured out and fixed in previous patches and `regex` newly gaining support for empty alternations, there is no reason to keep `re2` around anymore. It's only *marginally* faster at creating the regex which saves at most a couple of ms, but gets beaten by `regex` in every other aspect. This removes the Rust/C/C++ bridge (hooray!), the `with-re2` feature, the conditional code that goes with it, the documentation and relevant part of the debug/module output. Differential Revision: https://phab.mercurial-scm.org/D8594
-
- Mar 23, 2020
-
-
Raphaël Gomès authored
We do this periodically to say up to date. No major versions were crossed this time per se, but the `rand` is still in v0, and their 0.7x series broke three things: - Some distribution-related elements were moved to a separate crate, flashing a deprecation warning - The `LogNormal::new` associated function now returns a `Result` - Certain RNGs were updated to sample a `u32` instead of `usize` when their upper-bound is less than `u32::MAX` for better portability, which changed the output for 2 tests. Moreover, the recent use of the `regex` crate for ignore mechanisms prompted some benchmarking that revealed that `regex` was slower at compiling big regex than `Re2`. The author of `regex` was very quick to discover an optimization that yielded a 30% improvement. It's still slower than `Re2` in that regard, but less so in the 1.3.6 release. Differential Revision: https://phab.mercurial-scm.org/D8320
-
- Mar 18, 2020
-
-
Raphaël Gomès authored
The added `log` crate is already a sub-dependency. Differential Revision: https://phab.mercurial-scm.org/D8300
-
- Mar 06, 2020
-
-
Raphaël Gomès authored
This change adds the `log` crate, the community-approved logging facade backed by Rust core developers as well as the logging-consumer crate `simple_logger` to build a foundation for logging from Rust. Using this setup allows us to choose how to log depending on the way `hg-core` is used: if it's within the context of `hg-cpython`, we might not want to use it the same way as with a direct cli for example. Differential Revision: https://phab.mercurial-scm.org/D8252
-
- Jan 16, 2020
-
-
Raphaël Gomès authored
This assumes that Re2 is installed following Google's guide. I am not sure how we want to integrate it in the project, but I think a follow-up patch would be more appropriate for such work. As it stands, *not* having Re2 installed results in a compilation error, which is a problem as it breaks install compatibility. Hence, this is gated behind a non-default `with-re2` compilation feature. Differential Revision: https://phab.mercurial-scm.org/D7910
-
- Jan 30, 2020
-
-
Yuya Nishihara authored
-
- Oct 14, 2019
-
-
Yuya Nishihara authored
What I wanted is to disable the "cpython/extension-module<ver>" feature while building tests executable, but that seems not doable. Instead, this patch adds new features dedicated for tests. The make rule is extracted so that we can easily run cargo tests. Added a minimal test of ref-sharing as an example. More tests will follow.
-
- Oct 13, 2019
-
-
Yuya Nishihara authored
We no longer use it.
-
Yuya Nishihara authored
Unblocks py_capsule_fn!().
-
- Jul 02, 2019
-
-
Raphaël Gomès authored
Many interesting changes have happened in Rust since the Oxidation Plan was introduced, like the 2018 edition and procedural macros: - Opting in to the 2018 edition is a clear benefit in terms of future proofing, new (nice to have) syntactical sugar notwithstanding. It also has a new non-lexical, non-AST based borrow checker that has fewer bugs(!) and allows us to write correct code that in some cases would have been rejected by the old one. - Procedural macros allow us to use the PyO3 crate which maintainers have expressed the clear goal of compiling on stable, which would help in code maintainability compared to rust-cpython. In this patch are the following changes: - Removing most `extern crate` uses - Updating `use` clauses (`crate` keyword, nested `use`) - Removing `mod.rs` in favor of an aptly named module file Like discussed in the mailing list ( https://www.mercurial-scm.org/pipermail/mercurial-devel/2019-July/132316.html ), until Rust integration in Mercurial is considered to be out of the experimental phase, the maximum version of Rust allowed is whatever the latest version Debian packages. Differential Revision: https://phab.mercurial-scm.org/D6597
-
- Dec 17, 2018
-
-
Georges Racinet authored
Defined Cargo features for Python3, making them overall simpler to use, hooked them in build and made mercurial.rustext importable. This is tested with Python 3.6.7. Differential Revision: https://phab.mercurial-scm.org/D5446
-
- Dec 03, 2018
-
-
Georges Racinet authored
This changeset introduces the hg-cpython crate, that compiles as a shared library holding a whole Python package (mercurial.rustext), with only the empty 'ancestor' submodule for now. Such bindings will be easier and safer to develop and maintain that those of `hg-direct-ffi`. They don't involve C code, only unsafe Rust that's mostly isolated within the cpython crate. The long-term goal would be to import the provided modules, such as rustext.ancestor with mercurial.policy.importmod, same as we already do with cext modules. Differential Revision: https://phab.mercurial-scm.org/D5434
-