summaryrefslogtreecommitdiff
path: root/crates/tor-config
Commit message (Collapse)AuthorAgeFilesLines
* Bump versions of 0.x tor-* and arti-* cratesIan Jackson2024-04-301-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | for p in `cat ../u`; do cargo set-version --locked --offline -p $p; done where u contains tor-basic-utils tor-async-utils tor-error tor-config tor-units tor-geoip tor-rtcompat tor-rtmock tor-log-ratelim tor-rpcbase tor-memquota tor-llcrypto tor-protover tor-bytes tor-hscrypto tor-socksproto tor-checkable tor-cert 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 arti-client arti-rpcserver arti-hyper
* Switch to figment 1.0.18 and extract_lossyNick Mathewson2024-04-223-4/+4
| | | | | | | The new (dubiously named) `Figment::extract_lossy` method can treat decode numbers from strings, and booleans from numbers or strings. This makes the behavior compatible with config-rs, and should (I hope) finally allow us to migrate.
* Rename ConfigParseError => ConfigLoadErrorNick Mathewson2024-04-221-8/+15
| | | | | Figment can give an error under more conditions than just a parsing failure, so we should report it a bit more vaguely.
* Add an action field to Io error in tor-config.Nick Mathewson2024-04-222-15/+24
|
* Convert tor-config to use figment.Nick Mathewson2024-04-227-104/+138
| | | | | There are probably ways to make this a bit more elegant, but at least the tests still pass.
* Upgrade derive-deftly requirement to 0.10.3Nick Mathewson2024-04-111-1/+1
| | | | We're taking this for the fix to derive-deftly#52.
* Merge branch 'deftly' into 'main'Ian Jackson2024-04-033-30/+33
|\ | | | | | | | | Switch to derive-deftly See merge request tpo/core/arti!2066
| * derive-deftly: Change some docs referencesIan Jackson2024-04-031-4/+4
| | | | | | | | Found by "git grep adhoc" and manual inspection.
| * derive-deftly: Call pub_template_semver_checkIan Jackson2024-04-031-0/+2
| | | | | | | | | | | | | | This is a new feature in d-d 0.10.0. Our currrent semver policy doesn't care about this, but let's not encode that property in the tree and leave ourselves a booby-trap.
| * Switch to derive-deftlyIan Jackson2024-04-033-29/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the combination of a number of separate commits, many of which were generated by seddery, and then rebased and squashed. Cargo.toml perl -i~ -pe 's{^derive-adhoc}{derive-deftly = "0.10"}' crates/*/Cargo.toml (not regenerated during rebase) update Cargo.lock `cargo fetch` without --locked (regenerated during rebase) seddery git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{^use derive_adhoc}{use derive_deftly}' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\bdefine_derive_adhoc\b}{define_derive_deftly}g' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\bAdhoc\b}{Deftly}g if m{derive}' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\#\[derive_adhoc\b}{#[derive_deftly}g' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{use derive_adhoc}{use derive_deftly}' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\bderive_adhoc\b}{derive_deftly_adhoc} if m{use.*deftly}' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\bderive_adhoc!}{derive_deftly_adhoc!}' (not regenerated during rebase) Manually add `#[derive_deftly_adhoc]` where needed. seddery git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\#\[adhoc\b}{#[deftly}g' git-ls-files | grep '\.rs$' | xargs perl -i~ -pe 's{\bderive_adhoc_template}{derive_deftly_template}' (not regenerated during rebase) Manually fix up an import Manually update some builder attrs Manually fix up tor_rtmock::time_core This was missed in my seddery, due to me rebasing the branch and not redoing the seddery.
* | Remove semver.md files from arti-1.2.1 releaseNick Mathewson2024-04-021-5/+0
|/
* Update unstable `tor/arti-*` crates to 0.17.0.Nick Mathewson2024-04-021-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Done with: ``` CRATES=" tor-basic-utils tor-async-utils tor-error tor-config tor-events tor-units tor-geoip tor-rtcompat tor-rtmock tor-log-ratelim tor-rpcbase tor-llcrypto tor-protover tor-bytes tor-hscrypto tor-hspow tor-socksproto tor-checkable tor-cert tor-linkspec tor-cell tor-proto tor-netdoc tor-consdiff tor-netdir tor-relay-selection tor-congestion tor-persist tor-chanmgr tor-ptmgr tor-guardmgr tor-circmgr tor-dirclient tor-dirmgr tor-keymgr tor-hsclient tor-hsservice tor-hsrproxy arti-client arti-rpcserver arti-config arti-hyper arti-bench arti-testing " for crate in $CRATES; do cargo set-version -p "$crate" 0.17.0 done ```
* Bump patchlevel versions on non-{tor/arti} crates.Nick Mathewson2024-04-021-1/+1
| | | | | | | | | | | | | | | | These have all had backward-compatible changes. Generated with: ``` cargo set-version --bump patch -p fs-mistrust cargo set-version --bump patch -p test-temp-dir cargo set-version --bump patch -p fslock-guard cargo set-version --bump patch -p hashx cargo set-version --bump patch -p equix cargo set-version --bump patch -p caret cargo set-version --bump patch -p safelog cargo set-version --bump patch -p retry-error ```
* Merge branch 'encapsulate_config_rs' into 'main'Nick Mathewson2024-03-139-89/+131
|\ | | | | | | | | Encapsulate usage of config-rs inside tor-config. See merge request tpo/core/arti!2040
| * Grammar fix.gabi-2502024-03-131-1/+1
| |
| * Remove now-needless dependencies on the "config" crateNick Mathewson2024-03-131-1/+0
| | | | | | | | | | arti and arti-testing no longer need it; tor-config no longer needs it in dev-dependencies.
| * tor-config: Update documentation to not refer to config crate.Nick Mathewson2024-03-134-11/+12
| |
| * config: Remove From impls from config::ConfigErrorNick Mathewson2024-03-134-18/+18
| | | | | | | | These are another case of exposing the config crate.
| * tor-config: Put config::Config inside a wrapper type.Nick Mathewson2024-03-136-23/+34
| | | | | | | | This will let us replace Config with something better.
| * Use ConfigurationSource::Verbatim in our tests.Nick Mathewson2024-03-132-16/+24
| |
| * tor-config: Allow ConfigurationSource to be verbatim text.Nick Mathewson2024-03-132-12/+29
| | | | | | | | | | This will let us test our configuration logic without having to use the `config` crate directly.
| * tor_config: Hide macro-only re-exports.Nick Mathewson2024-03-133-12/+18
| | | | | | | | | | Our macros use these exports, but we don't need everybody else to be able to see them.
* | Run maint/add_warning.Nick Mathewson2024-03-1310-0/+10
|/
* Fix typos in doc commentsTobias Stoeckmann2024-03-061-1/+1
|
* Merge branch 'deny-unchecked-duration-substraction' into 'main'Ian Jackson2024-03-051-0/+1
|\ | | | | | | | | | | | | deny clippy::unchecked_duration_subtraction Closes #1304 See merge request tpo/core/arti!2008
| * deny clippy::unchecked_duration_subtractiontrinity-1686a2024-02-291-0/+1
| |
* | Bump the minor version, for crates with breaking changes.Gabriela Moldovan2024-03-041-1/+1
|/ | | | | | | | | | | | | | | | | | | | | | | | | | APIs were broken in these pre-1.0.0 crates: ``` tor-keymgr tor-config tor-checkable tor-circmgr tor-dirmgr tor-hsclient tor-hsservice tor-hsrproxy ``` Done with: ``` cargo set-version --bump minor -p tor-keymgr cargo set-version --bump minor -p tor-config cargo set-version --bump minor -p tor-checkable cargo set-version --bump minor -p tor-circmgr cargo set-version --bump minor -p tor-dirmgr cargo set-version --bump minor -p tor-hsclient cargo set-version --bump minor -p tor-hsservice cargo set-version --bump minor -p tor-hsrproxy ```
* Upgrade to latest config.Gabriela Moldovan2024-02-281-2/+2
|
* educe: Use std's default for two structsIan Jackson2024-02-121-3/+1
| | | | | | Reviewing uses of `#[educe(default)]`, I came across these two places where it was applied to a non-generic struct without any special attributes on fields. std's derive will do just as well here.
* educe: Use std's default for enums where default variant is unitIan Jackson2024-02-122-10/+6
| | | | | | | | | | | | | Since Rust 1.66, std's default works properly for enums, provided that the default variant is a unit. Review all uses of `#[educe(default)]` on enums and replace them with std where possible, which is most of them. In 1.66 and later, std's `#[derive(Default)]` doesn't infer any generic bounds on the derived impl, where it's an enum - since the unit variant can always be constructed. So this change doesn't add any generic bounds and is not API-visible.
* Bump patch versions *with* dependency updateIan Jackson2024-02-051-1/+1
| | | | | | | This crate has had new features added. It's 0.x. So bump in-tree dependencies' references: fs-mistrust
* Bump patch versions (without dependency updates)Ian Jackson2024-02-051-1/+1
| | | | | | | | | These crates have had trivial changes which have no implications for their dependencies: safelog tor-error tor-config
* Require tracing-test 0.2.4Ian Jackson2024-01-311-1/+1
| | | | | | Apparently we need https://github.com/dbrgn/tracing-test/pull/17 too.
* Require tracing-test 0.2.2Ian Jackson2024-01-311-1/+1
| | | | | | | | We need this bugfix https://github.com/dbrgn/tracing-test/pull/15 for `#[traced_test]` when `Result` is redefined. Fixes the tests with minimal-versions.
* Upgrade to strum 0.26Nick Mathewson2024-01-301-1/+1
|
* config: Fix output of NoCompileTimeSupport::withinNick Mathewson2024-01-161-1/+1
| | | | | Previously, within() would transform this error variant into Invalid.
* Patchlevel version bumps in preparation for 1.1.12.Nick Mathewson2024-01-091-1/+1
| | | | | | | | | | | | | This crate doesn't have a meaningful public API, so it just gets a patchlevel bump: arti These crates had nonbreaking changes, and get a patchlevel bump: tor-rtcompat fs-mistrust tor-llcrypto tor-cert
* Breaking version bumps in preparation for 1.1.12.Nick Mathewson2024-01-091-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These crates have breaking changes on their own: tor-error tor-netdoc tor-dirmgr tor-keymgr Because of the breaking change in tor-error, and the fact that basically every crate publicly depends on tor-error (by implementing ErrorKind), we need to call this a breaking change on all of the following: tor-config tor-geoip tor-rtmock tor-log-ratelim tor-rpcbase tor-bytes tor-hscrypto tor-socksproto tor-cell tor-proto tor-netdoc tor-netdir tor-persist tor-chanmgr tor-ptmgr tor-guardmgr tor-circmgr tor-dirclient tor-dirmgr tor-keymgr tor-hsclient tor-hsservice tor-hsrproxy arti-client arti-rpcserver arti-config arti-hyper arti-testing
* Fix typosDimitris Apostolou2024-01-081-1/+1
|
* Update to derive-adhoc 0.8Ian Jackson2024-01-021-1/+1
| | | | | As recommended in the d-a changelog, I'm not calling this a breaking change to our APIs.
* upgrade to toml 0.8.8Nick Mathewson2023-12-051-1/+1
|
* Merge branch 'msrv-followup' into 'main'Nick Mathewson2023-12-041-3/+1
|\ | | | | | | | | Followups from MSRV 1.70 upgrade See merge request tpo/core/arti!1785
| * tor-config: use black_box in test.Nick Mathewson2023-11-301-3/+1
| |
* | Bump patchlevel versions in preparation for releaseNick Mathewson2023-12-041-3/+3
|/ | | | | | | | | | | | | | | These crates had backward-compatible changes, and get a patchlevel bump only: fs-mistrust tor-error tor-config tor-rtcompat tor-rtmock This crate exposes no non-CLI APIs, and gets a patchlevel bump only: arti
* Merge branch 'msrv-bump-1.70' into 'main'Ian Jackson2023-11-301-1/+1
|\ | | | | | | | | Increase our MSRV to 1.70 See merge request tpo/core/arti!1773
| * In every crate, change rust-version to 1.70.Nick Mathewson2023-11-281-1/+1
| |
* | Require config ≥ 0.13.4Nick Mathewson2023-11-291-2/+2
|/ | | | | | | This version of the config crate includes a fix for the issue (https://github.com/mehcode/config-rs/issues/464) that had prevented us from using the format we had wanted for our rproxy configuration.
* Upgrade to itertools 0.12.0Nick Mathewson2023-11-151-1/+1
|
* Patch version bumps in crates without breaking changesNick Mathewson2023-10-311-1/+1
| | | | | | | | | | | | | | | | | | ``` These crates have new APIs: tor-async-utils ADDED tor-config ADDED tor-hscrypto ADDED tor-netdoc ADDED, plus BREAKING-experimental. These crates have patch-level changes only: tor-netdir (bugfix only). (re-exposes netdoc) arti-rpcserver (tweaks only, uses nothing that broke.) arti 1.1.10, no stable public APIs. ```
* Minor version bumps in crates with breaking changes.Nick Mathewson2023-10-311-1/+1
| | | | | | | | | | | | | | | | | | | | | | ``` tor-basic-utils BREAKING tor-rtmock BREAKING. tor-cert BREAKING tor-cell BREAKING tor-proto BREAKING: re-exposes cell. (Also BREAKING-experimental) tor-chanmgr BREAKING: Re-exposes proto. tor-ptmgr BREAKING: re-exposes tor-chanmgr tor-guardmgr BREAKING: re-exposes proto. (Only for ClockSkew I think?) tor-circmgr BREAKING: re-exposes proto tor-dirclient BREAKING tor-hsclient BREAKING, re-exposes proto. tor-hsservice BREAKING, re-exposes proto. tor-hsrproxy BREAKING arti-client BREAKING: re-exposes proto. arti-hyper: BREAKING, re-exposes arti-client. tor-dirmgr Let's assume BREAKING, very high-level. tor-keymgr BREAKING, but experimental. ```