annotate rust/hg-core/Cargo.toml @ 51723:9367571fea21

cext: correct the argument handling of `b85encode()` The type stub indicated that this argument is `Optional`, which implies None is allowed. I don't see in the documentation where that's the case for `i`[1], and trying it in `hg debugshell` resulted in the method failing with a TypeError. I guess it was typed as an `int` argument because the `p` format unit wasn't added until Python 3.3[2]. In any event, 2 clients in core (`pvec` and `obsolete`) call this with no argument supplied, and `mdiff` calls it with True. So I guess we've avoided the None arg case, and when no arg is supplied, it defaults to the 0 initialization of the `pad` variable in C. Since the `p` format unit accepts both `int` and None, as well as `bool`, I'm not bothering to bump the module version- this code is more permissive than it was, in addition to being more correct. Interestingly, when I first imported the `cext` and `pure` methods in the same manner as the previous commit, it dropped the `Optional` part of the argument type when generating `util.pyi`. No idea why. [1] https://docs.python.org/3/c-api/arg.html#numbers [2] https://docs.python.org/3/c-api/arg.html#other-objects
author Matt Harbison <matt_harbison@yahoo.com>
date Sat, 20 Jul 2024 01:55:09 -0400
parents a96ed440450e
children db7dbe6f7bb2
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
40271
dbc28c91f7ff rust: pure Rust lazyancestors iterator
Georges Racinet <gracinet@anybox.fr>
parents:
diff changeset
1 [package]
dbc28c91f7ff rust: pure Rust lazyancestors iterator
Georges Racinet <gracinet@anybox.fr>
parents:
diff changeset
2 name = "hg-core"
dbc28c91f7ff rust: pure Rust lazyancestors iterator
Georges Racinet <gracinet@anybox.fr>
parents:
diff changeset
3 version = "0.1.0"
dbc28c91f7ff rust: pure Rust lazyancestors iterator
Georges Racinet <gracinet@anybox.fr>
parents:
diff changeset
4 authors = ["Georges Racinet <gracinet@anybox.fr>"]
dbc28c91f7ff rust: pure Rust lazyancestors iterator
Georges Racinet <gracinet@anybox.fr>
parents:
diff changeset
5 description = "Mercurial pure Rust core library, with no assumption on Python bindings (FFI)"
49630
1b6be761c23d rust: move all crates in the main workspace to edition 2021
Raphaël Gomès <rgomes@octobus.net>
parents: 49595
diff changeset
6 edition = "2021"
40271
dbc28c91f7ff rust: pure Rust lazyancestors iterator
Georges Racinet <gracinet@anybox.fr>
parents:
diff changeset
7
dbc28c91f7ff rust: pure Rust lazyancestors iterator
Georges Racinet <gracinet@anybox.fr>
parents:
diff changeset
8 [lib]
dbc28c91f7ff rust: pure Rust lazyancestors iterator
Georges Racinet <gracinet@anybox.fr>
parents:
diff changeset
9 name = "hg"
41692
ee7b7bd432a1 rust: translated random test of missingancestors
Georges Racinet <gracinet@anybox.fr>
parents: 40271
diff changeset
10
42302
d1786c1d34fa rust-dirstate: add rust implementation of `parse_dirstate` and `pack_dirstate`
Raphaël Gomès <rgomes@octobus.net>
parents: 41692
diff changeset
11 [dependencies]
48953
ec8d9b5a5e7c rust-hg-core: upgrade dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 48950
diff changeset
12 bitflags = "1.3.2"
49935
da02e88b4850 rust-clippy: upgrade `bytes-cast` dependency
Raphaël Gomès <rgomes@octobus.net>
parents: 49913
diff changeset
13 bytes-cast = "0.3.0"
48953
ec8d9b5a5e7c rust-hg-core: upgrade dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 48950
diff changeset
14 byteorder = "1.4.3"
ec8d9b5a5e7c rust-hg-core: upgrade dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 48950
diff changeset
15 derive_more = "0.99.17"
49638
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
16 hashbrown = { version = "0.13.1", features = ["rayon"] }
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
17 home = "0.5.4"
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
18 im-rc = "15.1.0"
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
19 itertools = "0.10.5"
44599
d31d1c0685be rust: update all dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 44598
diff changeset
20 lazy_static = "1.4.0"
49638
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
21 libc = "0.2.137"
49913
c15b415d1bff rust: use `logging_timer` instead of `micro_timer`
Raphaël Gomès <rgomes@octobus.net>
parents: 49638
diff changeset
22 logging_timer = "1.1.0"
49638
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
23 rand = "0.8.5"
48554
0dc698c91ca0 rust: upgrade `rand*` crates
Martin von Zweigbergk <martinvonz@google.com>
parents: 48492
diff changeset
24 rand_pcg = "0.3.1"
48953
ec8d9b5a5e7c rust-hg-core: upgrade dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 48950
diff changeset
25 rand_distr = "0.4.3"
50297
3f31b8526d66 rust: upgrade `rayon` dependency
Raphaël Gomès <rgomes@octobus.net>
parents: 50296
diff changeset
26 rayon = "1.7.0"
49638
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
27 regex = "1.7.0"
50682
2cc5de261d76 rust-hg-core: move from `ouroboros` to `self_cell`
Raphaël Gomès <rgomes@octobus.net>
parents: 50298
diff changeset
28 self_cell = "1.0"
50763
f8412da86d05 rust-config: add support for default config items
Raphaël Gomès <rgomes@octobus.net>
parents: 50682
diff changeset
29 serde = { version = "1.0", features = ["derive"] }
48953
ec8d9b5a5e7c rust-hg-core: upgrade dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 48950
diff changeset
30 sha-1 = "0.10.0"
49638
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
31 twox-hash = "1.6.3"
44301
4caac36c66bc rust-utils: add util for canonical path
Raphaël Gomès <rgomes@octobus.net>
parents: 44266
diff changeset
32 same-file = "1.0.6"
49638
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
33 tempfile = "3.3.0"
50763
f8412da86d05 rust-config: add support for default config items
Raphaël Gomès <rgomes@octobus.net>
parents: 50682
diff changeset
34 toml = "0.6"
49581
04f1dba53c96 rust: create wrapper struct to reduce `regex` contention issues
Raphaël Gomès <rgomes@octobus.net>
parents: 49520
diff changeset
35 thread_local = "1.1.4"
49638
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
36 crossbeam-channel = "0.5.6"
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
37 log = "0.4.17"
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
38 memmap2 = { version = "0.5.8", features = ["stable_deref_trait"] }
50296
6abee333a200 rust: update zstd dependency
Raphaël Gomès <rgomes@octobus.net>
parents: 50174
diff changeset
39 zstd = "0.12"
48492
d3ec82016104 rust: Upgrade to format-bytes 0.3
Simon Sapin <simon.sapin@octobus.net>
parents: 48195
diff changeset
40 format-bytes = "0.3.0"
49638
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
41 once_cell = "1.16.0"
51260
c4f1a790bda8 rust-index: use a `BitVec` instead of plain `Vec` for heads computation
Raphaël Gomès <rgomes@octobus.net>
parents: 50763
diff changeset
42 bitvec = "1.0.1"
51391
a96ed440450e hg-core: implement timestamp line parsing
Arun Kulshreshtha <akulshreshtha@janestreet.com>
parents: 51260
diff changeset
43 chrono = "0.4.34"
45526
26c53ee51c68 hg-core: Add a limited read only `revlog` implementation
Antoine Cezar <antoine.cezar@octobus.net>
parents: 44935
diff changeset
44
45614
7bd13bf99d1c rust: update minimum supported Rust compiler version
Raphaël Gomès <rgomes@octobus.net>
parents: 45609
diff changeset
45 # We don't use the `miniz-oxide` backend to not change rhg benchmarks and until
7bd13bf99d1c rust: update minimum supported Rust compiler version
Raphaël Gomès <rgomes@octobus.net>
parents: 45609
diff changeset
46 # we have a clearer view of which backend is the fastest.
45526
26c53ee51c68 hg-core: Add a limited read only `revlog` implementation
Antoine Cezar <antoine.cezar@octobus.net>
parents: 44935
diff changeset
47 [dependencies.flate2]
49638
9726deed397c hg-core: upgrade all remaining dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 49637
diff changeset
48 version = "1.0.24"
45526
26c53ee51c68 hg-core: Add a limited read only `revlog` implementation
Antoine Cezar <antoine.cezar@octobus.net>
parents: 44935
diff changeset
49 features = ["zlib"]
26c53ee51c68 hg-core: Add a limited read only `revlog` implementation
Antoine Cezar <antoine.cezar@octobus.net>
parents: 44935
diff changeset
50 default-features = false
44265
c18dd48cea4a rust-pathauditor: add Rust implementation of the `pathauditor`
Raphaël Gomès <rgomes@octobus.net>
parents: 44158
diff changeset
51
c18dd48cea4a rust-pathauditor: add Rust implementation of the `pathauditor`
Raphaël Gomès <rgomes@octobus.net>
parents: 44158
diff changeset
52 [dev-dependencies]
50763
f8412da86d05 rust-config: add support for default config items
Raphaël Gomès <rgomes@octobus.net>
parents: 50682
diff changeset
53 clap = { version = "~4.0", features = ["derive"] }
48953
ec8d9b5a5e7c rust-hg-core: upgrade dependencies
Raphaël Gomès <rgomes@octobus.net>
parents: 48950
diff changeset
54 pretty_assertions = "1.1.0"