Commit Graph

3819 Commits

Author SHA1 Message Date
Ian Jackson baca49e087 config: Suppose that we might extend resolve_option to non-T::Default
As per point 3 in
  https://gitlab.torproject.org/tpo/core/arti/-/issues/488
2022-06-10 14:23:16 +01:00
Ian Jackson 77f33176c3 config: Do not strip_option for journald (and in future)
As per point 1 in
  https://gitlab.torproject.org/tpo/core/arti/-/issues/488
2022-06-10 14:23:13 +01:00
Ian Jackson abea103bb0 tor-error: Fix a broken intra-doc link
I didn't spot this in review amongst the other messages from Nightly.
2022-06-10 13:45:30 +01:00
Ian Jackson 03a19f3877 tor-bytes: read_nested_*: rustfmt
I disagree with almost all of these layout decisions...
2022-06-10 12:30:22 +01:00
Ian Jackson 8fe63b3192 tor-bytes: read_nested_*: Take a closure
This eliminates the possibility of writing the bug of failing to call
`should_be_exhausted`.

As per this discussion
  https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/572#note_2811464

Fixes #498
2022-06-10 12:27:00 +01:00
Ian Jackson a38c86a020 Merge branch 'format-ids' into 'main'
Replace four very similar "ids in request"

See merge request tpo/core/arti!577
2022-06-10 11:21:15 +00:00
Ian Jackson dc387e10a6 dirclient: Fix comments re conssensus request without authorities 2022-06-10 11:25:34 +01:00
Ian Jackson 605a988a60 Merge branch 'typos' into 'main'
Fix typos

See merge request tpo/core/arti!578
2022-06-10 10:19:37 +00:00
Dimitris Apostolou 9bbb0cf3dd
Fix typos 2022-06-10 07:03:50 +03:00
Ian Jackson 8731e45001 Merge branch 'nested-read-write' into 'main'
Introduce and use nested length reader/writers

See merge request tpo/core/arti!572
2022-06-09 16:46:19 +00:00
Nick Mathewson a2c6bd08fe Fix typos in docs and comments 2022-06-09 17:08:56 +01:00
Ian Jackson bcf3bca211 tor-cell: udp: Remove manual length calculations
This does away entirely with `wire_addr_len`, which recapitulates the
length calculation.
2022-06-09 17:08:56 +01:00
Ian Jackson 6f92bf9e86 tor-bytes: Provide nested writers 2022-06-09 17:08:56 +01:00
Ian Jackson a6a48c3c28 tor-bytes: Provide nested readers 2022-06-09 17:08:56 +01:00
Ian Jackson 04bca2e75a tor-bytes: Reader: Provide take_rest
We'll want this in a moment.
2022-06-09 17:08:56 +01:00
Ian Jackson 655804f804 tor-bytes: Prepare errors for nested reader/writer
Writing is going to be able to give errors too.
2022-06-09 17:08:56 +01:00
Ian Jackson 1c6ca6d286 channel padding timer: Explain why next() in select_biased! 2022-06-09 16:56:33 +01:00
Ian Jackson 9c92022663 channel padding timer: document state invariants
There aren't very many.
2022-06-09 16:31:11 +01:00
Ian Jackson be04c05cce Fix more typos in comments, from a spellchecker 2022-06-09 16:31:08 +01:00
Nick Mathewson e8999d0b57 Merge branch 'clippy' into 'main'
clippy: Allow dbg in tests *again*

See merge request tpo/core/arti!575
2022-06-09 15:17:09 +00:00
Nick Mathewson 2a53460d4e Merge branch 'topo' into 'main'
Fix topo sorting of Cargo.toml and reorganise CI jobs a bit

Closes #495

See merge request tpo/core/arti!576
2022-06-09 15:16:15 +00:00
Nick Mathewson b9db07fea9 Fix typo in comment 2022-06-09 15:01:56 +00:00
Nick Mathewson 1adc65ab53 Fix erroneous comment 2022-06-09 14:58:30 +00:00
Nick Mathewson 5815e14b94 Fix typos in comments 2022-06-09 14:58:17 +00:00
Nick Mathewson 38fcca7847 Fix typo in clippy-nightly.toml 2022-06-09 14:08:48 +00:00
Ian Jackson eb7bcc963b dirclient: Replace four very similar "ids in request"
In reviewing !553 I noticed that the empty digest list error had to be
handled in two places.  I filed #492 about the duplication.

In fact it turns out to have been quadruplication.

The new code also avoids cloning the underlying objects, instead
sorting a Vec of references.
2022-06-09 15:05:32 +01:00
Ian Jackson 361e1ba21b dirclient: Test consensus request based on empty ConsensusRequest
I'm not sure this is right.  But providing a test case for it before
my next change ensures that my refactoring doesn't change the
behaviour.
2022-06-09 15:03:44 +01:00
Ian Jackson 7e7cda1656 Merge branch 'less-servfail' into 'main'
return nodata instead of servfail in some instances

See merge request tpo/core/arti!564
2022-06-09 11:12:58 +00:00
Ian Jackson 86c4f42c49 CI: Break out maint/via-cargo-install 2022-06-08 19:32:59 +01:00
Ian Jackson d65c0023c5 CI: Break out some fastish Rust checks into new "build" step 2022-06-08 19:32:59 +01:00
Ian Jackson 9a8d75b844 CI: Break out some fast checks using debian image 2022-06-08 19:30:16 +01:00
Ian Jackson 84d5845eb6 maint/check_toposort: Run in CI 2022-06-08 18:35:56 +01:00
Ian Jackson 7c1f0e15b1 Revert toplevel part of "Lexically sort Cargo.toml dependencies"
This reverts one file from commit bfd41ddb5f.
2022-06-08 18:27:45 +01:00
Ian Jackson d00ba995be maint/cargo_sort: Tolerate toplevel Cargo.toml not being sorted 2022-06-08 18:27:45 +01:00
Ian Jackson ba016053de maint/toposort: Make shebang be python3, not python
Otherwise it doesn't work on sane systems where /usr/bin/python is
never an incompatible version from previously.
2022-06-08 17:17:20 +01:00
Ian Jackson 73c65d4c1a clippy: Allow dbg in tests *again*
*sigh*
2022-06-08 17:08:40 +01:00
Ian Jackson 3f2e164bc5 tor-proto: padding: Test padding timer distribution 2022-06-08 16:04:58 +01:00
Ian Jackson bbcdf9dd8b tor-proto: channel: Use padding::Timer 2022-06-08 16:04:58 +01:00
Ian Jackson 0027b2371f tor-proto: channel: Provide padding::Timer 2022-06-08 16:04:58 +01:00
Ian Jackson af92d72b39 Change to exhaustive match. 2022-06-08 16:02:22 +01:00
trinity-1686a e3c9152977 update semver.md 2022-06-08 16:02:22 +01:00
trinity-1686a 6c6998a65b try to differentiate transient from nontransient error 2022-06-08 16:02:01 +01:00
trinity-1686a 515a96a46e return nodata instead of servfail in some instances 2022-06-08 16:02:01 +01:00
Nick Mathewson 35fc0f444b Merge branch 'doc' into 'main'
Fix a doc link

See merge request tpo/core/arti!573
2022-06-08 14:34:09 +00:00
Ian Jackson 3260a9b720 Fix a second docs link 2022-06-08 14:41:22 +01:00
Ian Jackson 35664c33e2 Fix a doc link 2022-06-08 14:39:18 +01:00
Ian Jackson d202c3e9ca Merge branch 'sleep' into 'main'
Plumb a SleepProvider (now Clone + ....) into Channel

See merge request tpo/core/arti!569
2022-06-08 10:46:37 +00:00
Ian Jackson 8eb215bf81 Document semver changes 2022-06-08 11:24:26 +01:00
Ian Jackson e8fc1036d3 Plumb a SleepProvider into the channel reactor
The channel reactor is going to want to be able to sleep so that it
can do padding, so it needs a SleepProvider.
2022-06-08 11:24:26 +01:00
Ian Jackson 3ba3b26842 rt-compat: Make all the individual runtime traits Clone+Send etc.
This will make it much more convenient for code that only wants one of
these traits (or a subset of them).  This is a good thing to support
because it will allow us to use a ZST in places that do not need an
actual async runtime handle (typically, the runtime handle is needed
only for spawn).
2022-06-08 11:24:26 +01:00