summaryrefslogtreecommitdiff
path: root/crates/tor-dirclient
Commit message (Collapse)AuthorAgeFilesLines
* Patchlevel bumps for crates whose dependencies just changed.Nick Mathewson2023-03-311-2/+2
| | | | | | | | | | | | | | | | These crates had no changes until just a moment ago. But since we updated the versions on some of their dependents, they have now changed themselves. Thus they get patchlevel bumps. ``` tor-rtmock tor-protover tor-socksproto tor-consdiff tor-chanmgr tor-dirclient tor-hsservice ```
* Bump patchlevel on crates with non-breaking changesNick Mathewson2023-03-311-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For these crates, the changes are nontrivial, so we _do_ bump the versions on which their dependent crates depend. Fortunately, since they are all pre-1.0, we don't need to distinguish semver-additions from other changes. (Except for arti, which _is_ post-1.0, but gets a patchlevel bump anyway.) These are unstable crates with breaking changes: ``` tor-hscrypto tor-hsclient ``` These have new or extended APIs: ``` safelog tor-bytes tor-cell tor-linkspec tor-llcrypto tor-proto tor-cert arti-client ``` These have new unstable APIs or features: ``` tor-netdoc tor-circmgr (also broke some unstable APIs) arti (is post-1.0) ``` These have bugfixes only: ``` caret tor-dirmgr ```
* Patchlevel bumps for remaining changed crates.Nick Mathewson2023-02-281-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | These crates have had small code changes, but no API additions: tor-config tor-socksproto tor-cert tor-chanmgr tor-ptmgr tor-guardmgr tor-circmgr tor-dirclient tor-dirmgr arti tor-hsservice tor-congestion These crates have had API extensions: fs-mistrust tor-llcrypto tor-bytes tor-checkable tor-linkspec tor-netdoc tor-persist arti-client
* Bump minor versions for significant breaking changes.Nick Mathewson2023-02-281-1/+1
| | | | This includes tor-cell, tor-proto, and tor-netdir.
* Merge branch 'logs' into 'main'Nick Mathewson2023-02-011-2/+1
|\ | | | | | | | | | | | | Report causes of errors Closes #680 See merge request tpo/core/arti!997
| * tor-dirclient: De-genericise internal fn retire_circIan Jackson2023-01-301-2/+1
| | | | | | | | | | | | | | Requring `Display` is wrong here, because if this is actually an Error, Display would be wrong because it doesn't display causes. As it happens, the `error` parameter is only ever `&str`.
* | Bump the patch version of every crate that had API additionsNick Mathewson2023-02-011-3/+3
| | | | | | | | | | | | These crates had API or behavior changes that may affect downstream crates. Fortunately, they're all version 0.x, and don't need minor bumps for this.
* | Bump the patch-level version of crates with _minor_ changes.Nick Mathewson2023-02-011-5/+5
|/ | | | | | | These changes influence behavior, but not effect compatibility. (If I messed up, and any crate except for `arti` has non-breaking API changes, that's still fine, since they are all version 0.x.)
* Allow clippy::unchecked_duration_subtraction in testsNick Mathewson2023-01-274-0/+4
| | | | | This panics on error, and we're fine with a panic on misbehavior in tests.
* Disable clippy::unlinlined-format-argsNick Mathewson2023-01-271-0/+1
| | | | | | | | This warning kind of snuck up on us! (See #748) For now, let's disable it. (I've cleaned it up in a couple of examples, since those are meant to be more idiomatic and user-facing.) Closes #748.
* Complete our migration to base64ct.Nick Mathewson2023-01-202-2/+3
| | | | | | | | | This is in lieu of upgrading to the latest base64 crate, which has a different API from the old one. Since we have to migrate either way, we might as well use base64ct everywhere. I don't think that most of these cases _require_ constant-time base64, but it won't hurt.
* Merge branch 'test-lints' into 'main'eta2023-01-063-0/+24
|\ | | | | | | | | Add test lint blocks to all "mod test" See merge request tpo/core/arti!937
| * test lint blocks: Add many many automaticallyIan Jackson2022-12-123-0/+24
| | | | | | | | | | This is precisely the result of running the rune in maint/adhoc-add-lint-blocks.
* | doc: consistent summary line for the READMEsEmil Engler2022-12-201-1/+1
|/ | | | | This commit introduces a consistency to the summary line of all README.md files in each and every crate.
* Remove semver.md files now that 1.1.0 is released.Nick Mathewson2022-11-301-4/+0
|
* Bump the minor version of every crate.Nick Mathewson2022-11-301-10/+10
| | | | | We made this job easy this time around: by incrementing our MSRV, we have forced ourselves to do at least a minor bump everywhere.
* tor-dirclient: Replace OwnedChanTarget with LoggedChanTarget in SourceInfoIan Jackson2022-11-231-4/+4
| | | | | | | | | | | | | | | | SourceInfo primarily appears in errors, here and in (indirectly) tor-dirmgr. This 1. Makes the errors smaller 2. Redacts (currently, scrubs) the chantarget when safe logging is enabled This commit therefore deals with both tor-dirmgr and tor-dirclient errors, from the pov of error information that should become sensitive as part of bridge support. The error pyaloads directly in tor_dirmgr/src/err.rs don't seem to contain anything in that category.
* cfg compilation: Add two allowsIan Jackson2022-11-181-0/+1
|
* bump rust-version to 1.60 in every crate.Nick Mathewson2022-11-101-1/+1
|
* Suppress two clippy::large_enum_variant warningsNick Mathewson2022-11-031-0/+1
| | | | These are newly present on 1.65. We can address them later.
* Run add_warnings.Nick Mathewson2022-11-031-0/+1
|
* Require derive_more 0.99.3Ian Jackson2022-11-031-1/+1
| | | | | | | | 0.99.[012] have a bug https://github.com/JelteF/derive_more/issues/114 which makes the Deref derive for bridgedesc::StateGuard not work and therefore breaks minimal-versions CI. It seems simpler to require the newer version everywhere.
* tor-dirclient: Response: Provide into_output_stringIan Jackson2022-11-031-0/+11
| | | | | This is the missing one of the full set. It turns out that I wanted this rather than the non-consuming output_string.
* tor-dirclient: impl HasKind for RequestFailedErrorIan Jackson2022-10-251-1/+7
|
* tor-dirclient: Promise that download only gives RequestFailedIan Jackson2022-10-251-0/+4
|
* tor-dirclient::DirResponse: provide output_stringIan Jackson2022-10-251-0/+17
| | | | This gives callers a nice error type with source and everything.
* tor-dirclient: Provide RoutersOwnDescRequestIan Jackson2022-10-251-0/+29
| | | | This will be used for bridges' descriptors.
* tor-dirclient: Provide fallible DirResponse::output and into_outputIan Jackson2022-10-202-1/+82
|
* tor-dirclient: Make DirResponse be CloneIan Jackson2022-10-202-1/+2
| | | | I want this for testing. It seems friendly to provide it, though.
* tor-dirclient: Introduce RequestError:HttpStatusIan Jackson2022-10-201-0/+5
|
* tor-dirclient: Make RequestFailed its own error type (rustfmt)Ian Jackson2022-10-201-12/+18
| | | | Split off to assist review.
* tor-dirclient: Make RequestFailed its own error typeIan Jackson2022-10-203-26/+33
| | | | | | | We're going to have functions on Response that fail by returning only one of these. Sadly this diff is quite noisy.
* tor-dirclient Response: Rename output methodsIan Jackson2022-10-202-6/+10
| | | | | These don't check errors and are therefore quite hazardous. I'm going to introduce a more cooked version in a moment.
* cargo fmt to remove blank linesIan Jackson2022-10-121-1/+0
| | | | | | | Apparently cargo fmt doesn't like these, which my perl rune didn't delete. This commit is precisely the result of `cargo fmt`.
* Replace all README copies in src/lib.rs with includesIan Jackson2022-10-121-25/+1
| | | | | | | | The feature we want is `#[doc = include_str!("README.md")]`, which is stable since 1.54 and our MSRV is now 1.56. This commit is precisely the result of the following Perl rune: perl -i~ -0777 -pe 's{(^//!(?!.*\@\@).*\n)+}{#![doc = include_str!("../README.md")]\n}m' crates/*/src/lib.rs
* Bump minor version of tor-rtcompat and most of its dependentsNick Mathewson2022-10-031-6/+6
| | | | | | | (Since the APIs for the `Schedule::sleep*` functions changed, this is a breaking change in tor-rtcompat. Therefore, the Runtime trait in tor-rtcompat is now a different trait. Therefore, anything that uses the Runtime trait in its APIs has also broken.)
* Bump crates that have had backward compatible API changes.Nick Mathewson2022-10-031-3/+3
|
* Bump crate versions in preparation for Arti 1.0.0 release.Nick Mathewson2022-09-011-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Because we want to work more on ensuring that our semver stability story is solid, we are _not_ bumping arti-client to 1.0.0 right now. Here are the bumps we _are_ doing. Crates with "minor" bumps have had API breaks; crates with "patch" bumps have had new APIs added. Note that `tor-congestion` is not bumped here: it's a new crate, and hasn't been published before. ``` tor-basic-utils minor fs-mistrust minor tor-config minor tor-rtcompat minor tor-rtmock minor tor-llcrypto patch tor-bytes patch tor-linkspec minor tor-cell minor tor-proto minor tor-netdoc patch tor-netdir minor tor-persist patch tor-chanmgr minor tor-guardmgr minor tor-circmgr minor tor-dirmgr minor arti-client minor arti-hyper minor arti major arti-bench minor arti-testing minor ```
* Update patch-versions on crates without API changes.Nick Mathewson2022-09-011-1/+1
| | | | | | | Since our last round of releases, these crates have had either trivial changes, or changes that did not affect their APIs. Therefore we are bumping their versions, but not changing which versions of them other crates depend on.
* enable doc_auto_cfg feature on every crate when documenting for docs.rstrinity-1686a2022-08-242-0/+4
|
* Now that versions have bumped, remove semver.md files.Nick Mathewson2022-08-011-1/+0
|
* Bump patch versions on crates that have new APIs.Nick Mathewson2022-08-011-1/+1
| | | | | | | | | | | | | | Do _not_ bump the dependency versions on crates that have had no changes since arti 0.0.5, since those crates do not depend on the new APIs. ``` cargo set-version -p tor-basic-utils --bump patch cargo set-version -p tor-llcrypto --bump patch git restore crates/tor-checkable git restore crates/tor-consdiff git restore crates/tor-rtmock ```
* Bump minor version on crates with deps with breaking changes.Nick Mathewson2022-08-011-2/+2
| | | | | | | | | | | | | | | This performs the transitive closure of the last operation: everything that depends on a crate with a breaking change gets the version which it depends on bumped. ``` cargo set-version -p tor-proto --bump minor cargo set-version -p tor-netdoc --bump minor cargo set-version -p arti-hyper --bump minor cargo set-version -p arti-bench --bump minor cargo set-version -p arti-testing --bump minor cargo set-version -p tor-config --bump minor ```
* Bump minor versions on all crates that have had breaking changes.Nick Mathewson2022-08-011-3/+3
| | | | | | | | | | | | | | | | | | | | | | Done with these commands: ``` cargo set-version -p fs-mistrust --bump minor cargo set-version -p tor-bytes --bump minor cargo set-version -p tor-socksproto --bump minor cargo set-version -p tor-cert --bump minor cargo set-version -p tor-linkspec --bump minor cargo set-version -p tor-cell --bump minor cargo set-version -p tor-netdir --bump minor cargo set-version -p tor-persist --bump minor cargo set-version -p tor-chanmgr --bump minor cargo set-version -p tor-guardmgr --bump minor cargo set-version -p tor-circmgr --bump minor cargo set-version -p tor-dirclient --bump minor cargo set-version -p tor-dirmgr --bump minor cargo set-version -p arti-client --bump minor cargo set-version -p arti --bump minor ```
* Improve display for tor-dircache errors.Nick Mathewson2022-07-072-2/+15
| | | | | | | These errors no longer use Debug to dump the `Option<SourceInfo>`, but instead produce reasonable text. Also, I've fixed the SourceInfo Display implementation so that it now says that it got the error "from $source via $circuit" rather than the other way around.
* dirclient: Generalize MdSha256Empty to EmptyRequest.Nick Mathewson2022-07-073-6/+13
| | | | | (It makes sense to use this for things that are not in fact lists of SHA256 digests of Microdescriptors.)
* Bump crate and dependency versions.Nick Mathewson2022-06-241-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These were done with the following commands: ``` cargo set-version -p tor-basic-utils --bump patch cargo set-version -p fs-mistrust --bump minor cargo set-version -p tor-error --bump patch cargo set-version -p tor-config --bump patch cargo set-version -p tor-units --bump patch cargo set-version -p tor-rtcompat --bump minor cargo set-version -p tor-llcrypto --bump patch cargo set-version -p tor-bytes --bump minor cargo set-version -p tor-socksproto --bump minor cargo set-version -p tor-cert --bump minor cargo set-version -p tor-cell --bump minor cargo set-version -p tor-proto --bump minor cargo set-version -p tor-netdoc --bump patch cargo set-version -p tor-netdir --bump minor cargo set-version -p tor-persist --bump patch cargo set-version -p tor-chanmgr --bump minor cargo set-version -p tor-guardmgr --bump minor cargo set-version -p tor-circmgr --bump patch cargo set-version -p tor-dirclient --bump patch cargo set-version -p tor-dirmgr --bump minor cargo set-version -p arti-client --bump patch cargo set-version -p arti --bump minor cargo set-version -p arti-bench --bump minor cargo set-version -p arti-testing --bump minor ```
* Run maint/add_warning crates/*/src/{lib,main}.rsIan Jackson2022-06-231-0/+3
| | | | Update all lint blocks
* Do not include error source() in display() format.Nick Mathewson2022-06-211-3/+3
| | | | | | | | | According to doc/Errors.md, and in keeping with current best practices, we should not include display an error's `source()` as part of that error's display method. Instead, we should let the caller decide to call source() and display that error in turn. Part of #323.
* dirclient: Fix comments re conssensus request without authoritiesIan Jackson2022-06-101-5/+3
|