aboutsummaryrefslogtreecommitdiff
path: root/crates/tor-config
Commit message (Collapse)AuthorAgeFilesLines
...
* tor_config: Make ListBuilders implement ExtendBuilder.Nick Mathewson2025-12-091-0/+11
|
* tor-config: Give Flattenable template a location.Nick Mathewson2025-12-091-0/+1
| | | | | | If we don't do this, then any attempt to use it from a derive-deftly template will cause a warning about referring to it as $crate::macroname.
* tor-config: Allow Flattenable to apply to types with generics.Nick Mathewson2025-12-091-1/+2
|
* map_builder: Alternative syntax for use by derive(TorConfig)Nick Mathewson2025-12-091-5/+51
| | | | | | | | | | derive_deftly wants to expand types before passing them to macro_rules macros, which is quite reasonable. But map_builder wants its input collection type to be an `ident`, not a `path`. (And macro_rules doesn't accept `path` before a `<`.) To fix this, we're providing an alternative syntax for map_builder, where the inputs are the map type and the builder map type.
* extend_builder: Implement ExtendBuilder for HashMap.Nick Mathewson2025-12-091-1/+17
|
* tor-config: missing #[allow(dead_code)] in derive_list_builder_helperNick Mathewson2025-12-091-0/+1
|
* tor-config: missing $crate in derive_list_builder_helperNick Mathewson2025-12-091-1/+1
|
* tor-config: obviate need for Educe in derive_list_builder_helperNick Mathewson2025-12-091-2/+11
| | | | | | We were only using it for Default, and it is easier to implement Default by hand than it is to keep this particular layer in our leaning tower of macros.
* Update to derive-deftly 1.6.0Ian Jackson2025-12-031-1/+1
| | | | | | | | | This has: * Fixes to hygiene spans from the new modules feature, needed for my WIP netdoc encoder derive. * A substantially richer `${error }` construct.
* Merge branch 'listen' into 'main'opara2025-12-022-112/+313
|\ | | | | | | | | tor-config: Refactor `Listen` to make usable for arti-relay See merge request tpo/core/arti!3469
| * tor-config: improve comments about adding functionalitySteven Engler2025-12-021-5/+7
| |
| * tor-config: add more comments to `ListenItem`Steven Engler2025-12-021-1/+10
| |
| * tor-config: rename `Listen::is_localhost_only` to `is_loopback_only`Steven Engler2025-12-022-2/+11
| | | | | | | | Assumes that 0.37.0 will be the next version number.
| * tor-config: add new `CustomizableListen`Steven Engler2025-12-021-101/+193
| |
| * tor-config: fix some localhost vs loopback names/commentsSteven Engler2025-11-141-4/+5
| |
| * tor-config: made `InvalidListen` privateSteven Engler2025-11-142-1/+2
| | | | | | | | There was no reason for this to be public.
| * tor-config: simplify a match statementSteven Engler2025-11-141-8/+4
| | | | | | | | This does a little extra cloning, but I think is easier to read.
| * tor-config: add serde error messages to `ListenSerde` and `ListenItemSerde`Steven Engler2025-11-141-2/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For example the old message would look like: ```text target/debug/arti: error: read configuration: Config contents not as expected: Couldn't load configuration: data did not match any variant of untagged enum ListenSerde for key "default.proxy.socks_listen" in command line ``` The new message looks like: ```text target/debug/arti: error: read configuration: Config contents not as expected: Couldn't load configuration: value was not a bool, `u16` integer, string, or list of integers/strings for key "default.proxy.socks_listen" in command line ```
| * tor-config: add more tests for `Listen`Steven Engler2025-11-141-0/+81
| |
| * tor-config: remove unneeded `Serialize`/`Deserialize`Steven Engler2025-11-131-2/+1
| |
* | Bump all the unstable tor- and arti- crates to 0.37.0.Gabriela Moldovan2025-12-021-6/+6
| | | | | | | | | | | | | | | | | | Done using: ``` for crate in $(./maint/list_crates | rg '^(tor|arti-)'); do cargo set-version -p $crate 0.37.0 done
* | Bump the versions of the non-{arti-,tor-} cratesGabriela Moldovan2025-12-021-1/+1
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The non-{arti-,tor-} crates are: ``` ./maint/list_crates | rg -v '^(tor|arti)' oneshot-fused-workaround slotmap-careful test-temp-dir fslock-guard hashx equix caret fs-mistrust safelog retry-error futures-copy ``` We split them in the following categories: * crates with no changes (no version bumps): None ``` maint/changed_crates -v "arti-v$LAST_VERSION" 2>&1 >/dev/null | grep -i "no change" | grep -v '\(tor\|arti\)-' ``` * crates that only have non-functional changes (bump the patch version, but not the dependend-on version): - oneshot-fused-workaround - slotmap-careful - test-temp-dir - fslock-guard - equix - caret - safelog - retry-error * crates where functional changes were made, but no APIs were added or broken: - hashx - fs-mistrust - futures-copy * crates where APIs were broken (bump minor): None The bumps from this commit were created using this script: ``` PATCH_NF=( oneshot-fused-workaround slotmap-careful test-temp-dir fslock-guard equix caret safelog retry-error ) PATCH=" hashx fs-mistrust futures-copy " ./maint/bump_nodep "${PATCH_NF[@]}" for crate in $PATCH; do cargo set-version --bump patch -p $crate; done ```
* tor-config: fix error source for `ConfigLoadError`Steven Engler2025-11-131-1/+7
|
* Bump derive-deftly to 1.5.0Ian Jackson2025-11-071-1/+1
| | | | | | | This has the meta attributes with optional values feature and also hygiene rework for modules. The breaking changes don't break arti.
* Merge branch 'deftly-1.4' into 'main'opara2025-11-061-1/+1
|\ | | | | | | | | Bump derive-deftly to 1.4.0 See merge request tpo/core/arti!3448
| * Bump derive-deftly to 1.4.0Ian Jackson2025-11-061-1/+1
| | | | | | | | | | | | This will let us use the new modules feature. There are no breaking changes to beta features in 1.4.0.
* | Fix name of clippy lint to unchecked_time_subtraction (2)Ian Jackson2025-11-0613-14/+14
|/ | | | Run maint/add_warning
* maint: bump minor versions of all published cratesSteven Engler2025-10-291-8/+8
| | | | | | | ```bash readarray -t publish < <(cargo metadata --format-version 1 | jq -r '.packages[] | select((.id | startswith("path+file:///")) and (.rust_version != null) and (.publish == null or .publish == true or .publish != [])) | .name') for package in "${publish[@]}"; do echo "$package:"; cargo set-version --bump minor -p "$package"; done ```
* Bump MSRV from 1.85.1 to 1.86Clara Engler2025-10-211-1/+1
|
* tor-config: remove stale comment on `ConfigurationSources::try_from_cmdline`Steven Engler2025-10-081-2/+0
|
* tor-config: add `ConfigurationSources::options()`Steven Engler2025-10-081-0/+7
|
* release: Bump versions.Wesley Aptekar-Cassels2025-10-021-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Because we've updated our MSRV, we must bump the minor version for every package. This was done as follows: cargo set-version -p arti 1.6.0 cargo set-version -p oneshot-fused-workaround 0.4.0 cargo set-version -p slotmap-careful 0.4.0 cargo set-version -p test-temp-dir 0.5.0 cargo set-version -p fslock-guard 0.4.0 cargo set-version -p hashx 0.5.0 cargo set-version -p equix 0.4.0 cargo set-version -p caret 0.7.0 cargo set-version -p fs-mistrust 0.12.0 cargo set-version -p safelog 0.6.0 cargo set-version -p retry-error 0.8.0 xargs -I P <<END cargo set-version -p P 0.35.0 tor-basic-utils tor-error tor-general-addr tor-geoip tor-rtcompat tor-rtmock tor-async-utils tor-config tor-config-path tor-rpc-connect tor-log-ratelim tor-rpcbase tor-memquota tor-units tor-llcrypto tor-bytes tor-protover tor-checkable tor-cert tor-key-forge tor-hscrypto tor-socksproto tor-linkspec tor-cell tor-proto tor-netdoc tor-consdiff tor-netdir tor-relay-selection tor-persist tor-keymgr tor-chanmgr tor-ptmgr tor-dircommon tor-guardmgr tor-circmgr tor-dirclient tor-dirmgr tor-dirserver tor-hsclient tor-hsservice tor-hsrproxy tor-relay-crypto arti-client arti-relay arti-rpcserver arti-ureq arti-rpc-client-core END
* Remove "doc_auto_cfg" incantation from all crates.Nick Mathewson2025-09-291-1/+1
| | | | This feature has been removed from nightly, in favor of doc_cfg.
* config: clarify TODO on PaddingLevel.Nick Mathewson2025-09-171-1/+3
|
* Bump MSRV from 1.85 to 1.85.1Nick Mathewson2025-09-091-1/+1
| | | | Closes #2107
* Update to derive-deftly 1.3.0Ian Jackson2025-09-021-1/+1
|
* Bump the minor version of every published crate except for `arti`.Nick Mathewson2025-08-281-8/+8
| | | | | | | | Per policy, we bump the minor version of every tor-*, arti-* crate on each release. We have updated our MSRV, so we're treating this as a breaking change for our non-(arti/tor)-prefixed crates too.
* Merge branch 'toml-0.9.5' into 'main'Nick Mathewson2025-08-231-1/+1
|\ | | | | | | | | | | | | Upgrade to toml-0.9.5. Closes #2093 See merge request tpo/core/arti!3163
| * Upgrade to toml-0.9.5.Nick Mathewson2025-08-181-1/+1
| | | | | | | | Closes #2093.
* | clippy: fix `clippy::implicit_clone` errorsSteven Engler2025-08-111-1/+1
|/ | | | | | | | | | | | | | | | | ```text error: implicitly cloning a `String` by calling `to_string` on its dereferenced type --> crates/tor-config/src/lib.rs:109:32 | 109 | V::String(_, s) => s.to_string(), | ^^^^^^^^^^^^^ help: consider using: `s.clone()` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#implicit_clone note: the lint level is defined here --> crates/tor-config/src/lib.rs:20:9 | 20 | #![deny(clippy::implicit_clone)] | ^^^^^^^^^^^^^^^^^^^^^^ ```
* Switch Cargo.toml files to edition 2024.Nick Mathewson2025-08-076-7/+13
| | | | | | | | | | | | | | First, run ``` git grep -l "^edition =" | xargs perl -i -pe 's/^edition *=.*/edition = "2024"/;' ``` Second, manually verify that all Cargo.toml files have changed, and nothing else has changed. Third, run cargo fmt again.
* Set MSRV to 1.85.Nick Mathewson2025-08-051-1/+1
|
* Merge branch 'fix_rustdoc_nightly' into 'main'Nick Mathewson2025-08-051-1/+1
|\ | | | | | | | | Fix errors from rustdoc nightly. See merge request tpo/core/arti!3124
| * Fix errors from rustdoc nightly.Nick Mathewson2025-08-051-1/+1
| |
* | Bump version of tor-basic-utilsIan Jackson2025-08-051-2/+2
| | | | | | | | This was accidentally omitted from my version bump script.
* | Version bumps for 1.4.6Ian Jackson2025-08-051-4/+4
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Made with the following shell script: export CARGO='nailing-cargo -Eu' # Non-functional changes only maint/bump_nodep hashx # Special $CARGO set-version -p arti 1.4.6 # Additional features, no breaking changes, depended on in tree $CARGO set-version -p safelog 0.4.8 # Unconditional bump to 0.33.0 xargs -I P <<END $CARGO set-version -p P 0.33.0 tor-error tor-general-addr tor-geoip tor-rtcompat tor-rtmock tor-async-utils tor-config tor-config-path tor-rpc-connect tor-log-ratelim tor-rpcbase tor-memquota tor-units tor-llcrypto tor-bytes tor-protover tor-checkable tor-cert tor-key-forge tor-hscrypto tor-socksproto tor-linkspec tor-cell tor-proto tor-netdoc tor-consdiff tor-netdir tor-relay-selection tor-persist tor-chanmgr tor-ptmgr tor-guardmgr tor-circmgr tor-dirclient tor-dirmgr tor-keymgr tor-hsclient tor-hsservice tor-hsrproxy tor-relay-crypto arti-client arti-relay arti-rpcserver arti-ureq arti-rpc-client-core END
* Bump derive-deftly to 1.2.0Ian Jackson2025-08-041-1/+1
| | | | No upstream changes that break our code.
* tor-config: impl `NotAutoValue` for `ByteQty`Steven Engler2025-07-312-0/+4
|
* tor-config: add `ExplicitOrAuto::map` and `From<T> for ExplicitOrAuto<T>`Steven Engler2025-07-311-0/+18
|
* Bump all the unstable tor- and arti- crates to 0.32.0.Gabriela Moldovan2025-07-071-5/+5
| | | | | | | | | | Done using: ``` for crate in $(./maint/list_crates | rg '^(tor|arti-)'); do cargo set-version -p $crate 0.32.0 done ```