summaryrefslogtreecommitdiff
path: root/crates/tor-guardmgr/src/err.rs
Commit message (Collapse)AuthorAgeFilesLines
* tor-guardmgr: Use humantime for some logging.Wesley Aptekar-Cassels2025-10-161-1/+1
|
* tor-guardmgr: Include retry time in AllGuardsDown error message.Wesley Aptekar-Cassels2025-10-161-1/+6
| | | | | I don't love shoving such a complicated expression in thiserror, but it seems nicer than writing the implementation by hand...
* Switch Cargo.toml files to edition 2024.Nick Mathewson2025-08-071-4/+6
| | | | | | | | | | | | | | 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.
* tor-config: Rename to ReconfigureError::UnsupportedSituationIan Jackson2022-11-241-1/+1
| | | | | | | | From Unsupported. Prompted by https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/889#note_2856873 This was added in this MR. Also add the missing semver note.
* tor-guardmgr: Refuse to configure bridges if we don't have the lockIan Jackson2022-11-231-1/+15
| | | | Fixes #612
* tor-guardmgr: make replace_bridge_config fallibleIan Jackson2022-11-231-0/+30
| | | | | | The error type needs to be convertible to GuardMgrError and also to ReconfigureError. Neither of those is right, so we need a new error type.
* Remove now-unused NoGuardsUsable case.Nick Mathewson2022-07-071-8/+2
|
* Improve message for failure to select a guard.Nick Mathewson2022-07-071-2/+18
| | | | This uses similar techniques to the commit I just did for Fallbacks.
* Add more information to failed-to-select fallback errors.Nick Mathewson2022-07-071-2/+13
| | | | Also re-order the filters to be a little more logical.
* GuardMgr: tweak an error message.Nick Mathewson2022-07-061-1/+1
|
* GuardMgr: remove disallowed addresses from returned FirstHops.Nick Mathewson2022-06-171-1/+9
| | | | | | | | Since a guard can have a bunch of addresses, and the guard is permitted if any one of those addresses is permitted, then we might decide to use a guard with some non-permitted addresses. Thus, we need to filter those addresses before returning the view of the guard as a FirstHop.
* guardmgr: implement HasRetryTime.Nick Mathewson2022-04-041-0/+24
|
* Turn FallbackList into a real type, and store one in GuardMgr.Nick Mathewson2022-03-301-2/+13
| | | | | | | | | | | | | | The guard manager is responsible for handing out the first hops of tor circuits, keeping track of their successes and failures, and remembering their states. Given that, it makes sense to store this information here. It is not yet used; I'll be fixing that in upcoming commits. Arguably, this information no longer belongs in the directory manager: I've added a todo about moving it. This commit will break compilation on its own in a couple of places; subsequent commits will fix it up.
* guardmgr: move error types into new err.rs module.Nick Mathewson2022-03-301-0/+75
This is more in keeping with the rest of our code.