rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5 heartwood69fe26ceccf605df3063be6c75a69c89ed23de06
{
"request": "trigger",
"version": 1,
"event_type": "patch",
"repository": {
"id": "rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5",
"name": "heartwood",
"description": "Radicle Heartwood Protocol & Stack",
"private": false,
"default_branch": "master",
"delegates": [
"did:key:z6MksFqXN3Yhqk8pTJdUGLwATkRfQvwZXPqR2qMEhbS9wzpT",
"did:key:z6MktaNvN1KVFMkSRAiN4qK5yvX1zuEEaseeX5sffhzPZRZW",
"did:key:z6MkireRatUThvd3qzfKht1S44wpm4FEWSSa4PRMTSQZ3voM",
"did:key:z6MkgFq6z5fkF2hioLLSNu1zP2qEL1aHXHZzGH1FLFGAnBGz",
"did:key:z6MkkPvBfjP4bQmco5Dm7UGsX2ruDBieEHi8n9DVJWX5sTEz"
]
},
"action": "Updated",
"patch": {
"id": "511ad5ad569fea9124a9ad4738431e42b5075675",
"author": {
"id": "did:key:z6MkireRatUThvd3qzfKht1S44wpm4FEWSSa4PRMTSQZ3voM",
"alias": "fintohaps"
},
"title": "`radicle-protocol`: Sans-IO-ification",
"state": {
"status": "draft",
"conflicts": []
},
"before": "a8dac56ca645fdd98955766f07abe7cdd8980e56",
"after": "69fe26ceccf605df3063be6c75a69c89ed23de06",
"commits": [
"69fe26ceccf605df3063be6c75a69c89ed23de06",
"ba174752c6a62186f0e79e8759d65ac9edc166e5",
"ca9e9a27961c8d55024877b54c24abfd8c105f43"
],
"target": "a8dac56ca645fdd98955766f07abe7cdd8980e56",
"labels": [],
"assignees": [],
"revisions": [
{
"id": "511ad5ad569fea9124a9ad4738431e42b5075675",
"author": {
"id": "did:key:z6MkireRatUThvd3qzfKht1S44wpm4FEWSSa4PRMTSQZ3voM",
"alias": "fintohaps"
},
"description": "Exploring the conversion of `radicle-protocol` into a true sans-IO approach.",
"base": "efeefd0daa35682a3ff07bd6c24d73248252149f",
"oid": "7698f637656e8a225e04018a316294d3b731754e",
"timestamp": 1753429876
},
{
"id": "da4871b6df673e412bff3e7f731f2009781f3ccf",
"author": {
"id": "did:key:z6MkireRatUThvd3qzfKht1S44wpm4FEWSSa4PRMTSQZ3voM",
"alias": "fintohaps"
},
"description": "Changes:\n- Rebased\n- First sketch of a `Connections` state machine",
"base": "a8dac56ca645fdd98955766f07abe7cdd8980e56",
"oid": "ba174752c6a62186f0e79e8759d65ac9edc166e5",
"timestamp": 1754575831
},
{
"id": "418864d9ea7d9ff97cda5c76af0dcf348845cc52",
"author": {
"id": "did:key:z6MkireRatUThvd3qzfKht1S44wpm4FEWSSa4PRMTSQZ3voM",
"alias": "fintohaps"
},
"description": "Adding a fetch state machine",
"base": "a8dac56ca645fdd98955766f07abe7cdd8980e56",
"oid": "69fe26ceccf605df3063be6c75a69c89ed23de06",
"timestamp": 1754655542
}
]
}
}
{
"response": "triggered",
"run_id": {
"id": "3b386d3c-cd9e-471c-9b6c-b1ec80313805"
},
"info_url": "https://cci.rad.levitte.org//3b386d3c-cd9e-471c-9b6c-b1ec80313805.html"
}
Started at: 2025-08-08 14:19:05.149918+02:00
Commands:
$ rad clone rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5 .
✓ Creating checkout in ./...
✓ Remote cloudhead@z6MksFqXN3Yhqk8pTJdUGLwATkRfQvwZXPqR2qMEhbS9wzpT added
✓ Remote-tracking branch cloudhead@z6MksFqXN3Yhqk8pTJdUGLwATkRfQvwZXPqR2qMEhbS9wzpT/master created for z6MksFq…bS9wzpT
✓ Remote cloudhead@z6MktaNvN1KVFMkSRAiN4qK5yvX1zuEEaseeX5sffhzPZRZW added
✓ Remote-tracking branch cloudhead@z6MktaNvN1KVFMkSRAiN4qK5yvX1zuEEaseeX5sffhzPZRZW/master created for z6MktaN…hzPZRZW
✓ Remote fintohaps@z6MkireRatUThvd3qzfKht1S44wpm4FEWSSa4PRMTSQZ3voM added
✓ Remote-tracking branch fintohaps@z6MkireRatUThvd3qzfKht1S44wpm4FEWSSa4PRMTSQZ3voM/master created for z6Mkire…SQZ3voM
✓ Remote erikli@z6MkgFq6z5fkF2hioLLSNu1zP2qEL1aHXHZzGH1FLFGAnBGz added
✓ Remote-tracking branch erikli@z6MkgFq6z5fkF2hioLLSNu1zP2qEL1aHXHZzGH1FLFGAnBGz/master created for z6MkgFq…FGAnBGz
✓ Remote lorenz@z6MkkPvBfjP4bQmco5Dm7UGsX2ruDBieEHi8n9DVJWX5sTEz added
✓ Remote-tracking branch lorenz@z6MkkPvBfjP4bQmco5Dm7UGsX2ruDBieEHi8n9DVJWX5sTEz/master created for z6MkkPv…WX5sTEz
✓ Repository successfully cloned under /opt/radcis/ci.rad.levitte.org/cci/state/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/
╭────────────────────────────────────╮
│ heartwood │
│ Radicle Heartwood Protocol & Stack │
│ 114 issues · 12 patches │
╰────────────────────────────────────╯
Run `cd ./.` to go to the repository directory.
Exit code: 0
$ rad patch checkout 511ad5ad569fea9124a9ad4738431e42b5075675
✓ Switched to branch patch/511ad5a at revision 418864d
✓ Branch patch/511ad5a setup to track rad/patches/511ad5ad569fea9124a9ad4738431e42b5075675
Exit code: 0
$ git config advice.detachedHead false
Exit code: 0
$ git checkout 69fe26ceccf605df3063be6c75a69c89ed23de06
HEAD is now at 69fe26ce protocol: fetch state
Exit code: 0
$ git show 69fe26ceccf605df3063be6c75a69c89ed23de06
commit 69fe26ceccf605df3063be6c75a69c89ed23de06
Author: Fintan Halpenny <fintan.halpenny@gmail.com>
Date: Fri Aug 8 13:13:04 2025 +0100
protocol: fetch state
Similar to previous efforts, this change takes the fetching slice of the
`Service` and attempts to capture a sans-IO implementation of it.
It essentially translates `Service::fetch` into the `FetchState` machine. What's
important to note here is that it does not entangle the idea of sessions with
the idea of fetching. The state is purely based on `NodeId`s and `RepoId`s.
Note here that a layer above would make sure that connected sessions, using the
`Connections` state, would perform fetches and using `FetchState`.
diff --git a/crates/radicle-protocol/src/fetcher.rs b/crates/radicle-protocol/src/fetcher.rs
new file mode 100644
index 00000000..614ea15c
--- /dev/null
+++ b/crates/radicle-protocol/src/fetcher.rs
@@ -0,0 +1,484 @@
+pub mod commands;
+pub use commands::Command;
+pub mod effects;
+pub mod events;
+
+use std::collections::{BTreeMap, HashSet, VecDeque};
+use std::time;
+
+use nonempty::NonEmpty;
+
+use radicle::identity::DocAt;
+use radicle::node;
+use radicle::node::NodeId;
+use radicle::prelude::RepoId;
+use radicle::storage::{refs::RefsAt, RefUpdate};
+
+// TODO(finto): I think this should be defined here, and the worker should
+// provide the result based on this.
+type WorkerResult = Result<crate::worker::fetch::FetchResult, crate::worker::FetchError>;
+
+// TODO(finto): `Service::fetch_refs_at` and the use of `refs_status_of` is a
+// layer above the `Fetcher` where it would perform I/O, mocked out by a trait,
+// to check if there are wants and add a fetch to the Fetcher.
+
+/// Maximum items in the fetch queue.
+pub const MAX_FETCH_QUEUE_SIZE: usize = 128;
+
+/// Maintain the state of ongoing and queued fetches.
+pub struct FetcherState {
+ fetching: BTreeMap<NodeId, Fetching>,
+ queues: BTreeMap<NodeId, Queue>,
+ config: Config,
+}
+
+impl FetcherState {
+ /// Transition the state of ongoing fetches by recording new fetches that
+ /// are occurring, queuing them is the node if required, attempting to
+ /// dequeue fetches, and marking fetches as complete.
+ pub fn handle_command(&mut self, command: Command) -> Vec<Command> {
+ match command {
+ Command::Fetch(fetch) => self.handle_fetch(fetch),
+ Command::Fetched(fetched) => self.handle_fetched(fetched),
+ }
+ }
+
+ fn handle_fetch(&mut self, fetch: commands::Fetch) -> Vec<Command> {
+ let mut commands = Vec::new();
+ match fetch {
+ commands::Fetch::Repository { from, rid, .. } => {
+ let fetching = self.fetching.entry(from).or_default();
+ fetching.fetching(
+ rid,
+ FetchingFor {
+ from,
+ refs_at: vec![],
+ },
+ );
+ }
+ commands::Fetch::RefsAt {
+ from, rid, refs_at, ..
+ } => {
+ let fetching = self.fetching.entry(from).or_default();
+ fetching.fetching(
+ rid,
+ FetchingFor {
+ from,
+ refs_at: refs_at.into(),
+ },
+ );
+ }
+ commands::Fetch::Queue {
+ from,
+ rid,
+ refs_at,
+ timeout,
+ } => {
+ let queue = self
+ .queues
+ .entry(from)
+ .or_insert(Queue::new(self.config.maximum_queue_size));
+ match queue.enqueue(QueuedFetch {
+ rid,
+ from,
+ refs_at,
+ timeout,
+ }) {
+ Enqueue::CapacityReached(queued_fetch) => {
+ commands.push(commands::Fetch::from(queued_fetch).into());
+ }
+ Enqueue::Duplicate(queued_fetch) => {
+ commands.push(commands::Fetch::from(queued_fetch).into());
+ }
+ Enqueue::Queued => { /* TODO(finto): I think we also want to return events */ }
+ }
+ }
+ }
+ commands
+ }
+
+ fn handle_fetched(&mut self, fetched: commands::Fetched) -> Vec<Command> {
+ let mut commands = Vec::new();
+ match fetched {
+ commands::Fetched::DequeueFetches => {
+ self.deuque_fetches(&mut commands);
+ commands
+ }
+ commands::Fetched::Fetched { from, rid } => {
+ self.fetched_from(&from, &rid);
+ vec![]
+ }
+ }
+ }
+
+ fn deuque_fetches(&mut self, commands: &mut Vec<Command>) {
+ for queue in self.queues.values_mut() {
+ if let Some(QueuedFetch {
+ rid,
+ from,
+ refs_at,
+ timeout,
+ }) = queue.dequeue()
+ {
+ let command = NonEmpty::from_vec(refs_at).map_or(
+ commands::Fetch::Repository { from, rid, timeout },
+ |refs_at| commands::Fetch::RefsAt {
+ from,
+ rid,
+ refs_at,
+ timeout,
+ },
+ );
+ commands.push(command.into());
+ }
+ }
+ }
+
+ fn fetched_from(&mut self, node: &NodeId, rid: &RepoId) -> Option<FetchingFor> {
+ let fetching = self.fetching.get_mut(node)?;
+ fetching.fetched(rid)
+ }
+}
+
+impl FetcherState {
+ /// The protocol wishes to fetch the [`RepoId`] from the given [`NodeId`],
+ /// with the specified set of [`RefsAt`].
+ ///
+ /// This will result in a [`FetchResult`], reporting back to the protocol
+ /// what events occurred, which effects should performed, and the commands
+ /// to transition the state using [`FetchState::handle_command`].
+ pub fn fetch(
+ &self,
+ rid: RepoId,
+ from: NodeId,
+ refs_at: Vec<RefsAt>,
+ timeout: time::Duration,
+ ) -> FetchResult {
+ let mut result = FetchResult::default();
+ if let Some(fetching) = self.is_fetching(&from, &rid) {
+ result.queue_fetch(rid, from, refs_at, timeout);
+ result.already_fetching(rid, fetching.clone());
+ return result;
+ }
+
+ if self.is_at_capacity(&from) {
+ result.queue_fetch(rid, from, refs_at, timeout);
+ result.capacity_reached();
+ return result;
+ }
+
+ match NonEmpty::from_vec(refs_at) {
+ Some(refs_at) => result.fetch_refs_at(from, rid, refs_at, timeout),
+ None => result.fetch_repository(from, rid, timeout),
+ }
+ result
+ }
+
+ /// The protocol wishes to mark the fetch for [`RepoId`] from the given
+ /// [`NodeId`] as done, with the specified [`WorkerResult`].
+ ///
+ /// This will result in a [`FetchedResult`], reporting back to the protocol
+ /// what events occurred, which effects should performed, and the commands
+ /// to transition the state using [`FetchState::handle_command`].
+ pub fn fetched(&self, from: NodeId, rid: RepoId, worker_result: WorkerResult) -> FetchedResult {
+ let mut result = FetchedResult::default();
+ if self.is_fetching(&from, &rid).is_none() {
+ result.unexpected(from, rid);
+ return result;
+ };
+ match worker_result {
+ Ok(success) => {
+ if success.clone && success.doc.is_public() {
+ result.public_repo(rid);
+ }
+ if !success.updated.is_empty() && !success.updated.iter().all(|u| u.is_skipped()) {
+ result.announce(rid, success.doc, success.namespaces.clone());
+ }
+ result.refs_fetched(from, rid, success.updated.clone());
+ let node_result = node::FetchResult::Success {
+ updated: success.updated,
+ namespaces: success.namespaces,
+ clone: success.clone,
+ };
+ result.notify(from, rid, node_result);
+ }
+ Err(e) => {
+ if e.is_timeout() {
+ result.disconnect(from, e.to_string());
+ }
+ let node_result = node::FetchResult::Failed {
+ reason: e.to_string(),
+ };
+ result.notify(from, rid, node_result);
+ }
+ };
+
+ result.dequeue_fetches();
+ result
+ }
+
+ /// Get the [`FetchingFor`] for the provided [`NodeId`] and [`RepoId`],
+ /// returning `None` if it does not exist.
+ fn is_fetching(&self, node: &NodeId, rid: &RepoId) -> Option<&FetchingFor> {
+ self.fetching.get(node).and_then(|f| f.is_fetching(rid))
+ }
+
+ /// Check if the number of fetches exceeds the maximum number of concurrent
+ /// fetches for a given [`NodeId`].
+ fn is_at_capacity(&self, node: &NodeId) -> bool {
+ let number_of_fetches = self.fetching.get(node).map_or(0, |f| f.number_of_fetches());
+ number_of_fetches > self.config.maximum_concurrency
+ }
+}
+
+/// Configuration for the [`FetchState`].
+pub struct Config {
+ /// Maximum number of concurrent fetches per peer connection.
+ maximum_concurrency: usize,
+ /// Maximum fetching queue size for a single node.
+ maximum_queue_size: MaxQueueSize,
+}
+
+/// Fetch state for an ongoing fetch.
+#[derive(Clone, Debug, PartialEq, Eq)]
+pub struct FetchingFor {
+ /// Node we're fetching from.
+ from: NodeId,
+ /// What refs we're fetching.
+ refs_at: Vec<RefsAt>,
+}
+
+impl FetchingFor {
+ pub fn new(from: NodeId, refs_at: Vec<RefsAt>) -> Self {
+ Self { from, refs_at }
+ }
+}
+
+/// Keep track of which repositories are being fetched, and which node and
+/// `rad/sigrefs` they are fetching.
+#[derive(Clone, Debug, Default, PartialEq, Eq)]
+struct Fetching {
+ inner: BTreeMap<RepoId, FetchingFor>,
+}
+
+impl Fetching {
+ /// Get the number of fetches currently happening.
+ fn number_of_fetches(&self) -> usize {
+ self.inner.len()
+ }
+
+ /// Inspect the [`FetchingFor`] of the [`RepoId`].
+ fn is_fetching(&self, rid: &RepoId) -> Option<&FetchingFor> {
+ self.inner.get(rid)
+ }
+
+ /// The [`RepoId`] is currently being fetched.
+ fn fetching(&mut self, rid: RepoId, state: FetchingFor) {
+ self.inner.insert(rid, state);
+ }
+
+ /// The [`RepoId`] has been fetched.
+ fn fetched(&mut self, rid: &RepoId) -> Option<FetchingFor> {
+ self.inner.remove(rid)
+ }
+}
+
+/// Fetch waiting to be processed, in the fetch queue.
+#[derive(Debug, Clone, PartialEq, Eq)]
+pub struct QueuedFetch {
+ /// Repo being fetched.
+ pub rid: RepoId,
+ /// Peer being fetched from.
+ pub from: NodeId,
+ /// Refs being fetched.
+ pub refs_at: Vec<RefsAt>,
+ /// The timeout given for the fetch request.
+ pub timeout: time::Duration,
+}
+
+impl From<QueuedFetch> for commands::Fetch {
+ fn from(
+ QueuedFetch {
+ rid,
+ from,
+ refs_at,
+ timeout,
+ }: QueuedFetch,
+ ) -> Self {
+ Self::Queue {
+ from,
+ rid,
+ refs_at,
+ timeout,
+ }
+ }
+}
+
+/// A queue for keeping track of fetches.
+///
+/// It ensures that the queue contains unique items for fetching, and does not
+/// exceed the provided maximum capacity.
+struct Queue {
+ queue: VecDeque<QueuedFetch>,
+ max_queue_size: MaxQueueSize,
+}
+
+/// The maximum number of fetches that can be queued for a single node.
+#[derive(Clone, Copy, Debug, PartialEq, Eq, PartialOrd, Ord)]
+pub struct MaxQueueSize(usize);
+
+impl MaxQueueSize {
+ /// Checks if the `n` provided exceeds the maximum queue size.
+ fn is_exceeded_by(&self, n: usize) -> bool {
+ n >= self.0
+ }
+}
+
+impl Default for MaxQueueSize {
+ fn default() -> Self {
+ Self(MAX_FETCH_QUEUE_SIZE)
+ }
+}
+
+/// The result of [`Queue::enqueue`].
+pub enum Enqueue {
+ /// The capacity of the queue has been exceeded, and the [`QueuedFetch`] is
+ /// returned.
+ CapacityReached(QueuedFetch),
+ /// The [`QueuedFetch`] was a duplicate.
+ Duplicate(QueuedFetch),
+ /// The [`QueuedFetch`] was successfully queued.
+ Queued,
+}
+
+impl Queue {
+ /// Create the [`Queue`] with the given [`MaxQueueSize`].
+ fn new(max_queue_size: MaxQueueSize) -> Self {
+ Self {
+ queue: VecDeque::with_capacity(max_queue_size.0),
+ max_queue_size,
+ }
+ }
+
+ /// Enqueues a fetch onto the back of the queue, and will only succeed if
+ /// the queue has not reached capacity and if the item is unique.
+ fn enqueue(&mut self, fetch: QueuedFetch) -> Enqueue {
+ if self.max_queue_size.is_exceeded_by(self.queue.len()) {
+ Enqueue::CapacityReached(fetch)
+ } else if self.queue.contains(&fetch) {
+ Enqueue::Duplicate(fetch)
+ } else {
+ self.queue.push_back(fetch);
+ Enqueue::Queued
+ }
+ }
+
+ /// Dequeues a fetch from the front of the queue.
+ fn dequeue(&mut self) -> Option<QueuedFetch> {
+ self.queue.pop_front()
+ }
+}
+
+/// Events, effects, and commands that occur from [`FetchState::fetch`].
+#[derive(Clone, Debug, Default, PartialEq, Eq)]
+pub struct FetchResult {
+ /// Events that can be recorded by the rest of the system.
+ pub events: Vec<events::Fetch>,
+ /// Commands to progress [`FetchState`].
+ pub commands: Vec<commands::Fetch>,
+}
+
+impl FetchResult {
+ fn capacity_reached(&mut self) {
+ self.events.push(events::Fetch::CapacityReached);
+ }
+
+ fn already_fetching(&mut self, rid: RepoId, fetching: FetchingFor) {
+ self.events
+ .push(events::Fetch::AlreadyFetching { rid, fetching });
+ }
+
+ fn fetch_repository(&mut self, from: NodeId, rid: RepoId, timeout: time::Duration) {
+ self.commands
+ .push(commands::Fetch::Repository { from, rid, timeout });
+ }
+
+ fn fetch_refs_at(
+ &mut self,
+ from: NodeId,
+ rid: RepoId,
+ refs_at: NonEmpty<RefsAt>,
+ timeout: time::Duration,
+ ) {
+ self.commands.push(commands::Fetch::RefsAt {
+ from,
+ rid,
+ refs_at,
+ timeout,
+ });
+ }
+
+ fn queue_fetch(
+ &mut self,
+ rid: RepoId,
+ from: NodeId,
+ refs_at: Vec<RefsAt>,
+ timeout: time::Duration,
+ ) {
+ self.commands.push(commands::Fetch::Queue {
+ rid,
+ from,
+ refs_at,
+ timeout,
+ });
+ }
+}
+
+/// Events, effects, and commands that occur from [`FetchState::fetched`].
+#[derive(Clone, Debug, Default, PartialEq, Eq)]
+pub struct FetchedResult {
+ /// Events that can be recorded by the rest of the system.
+ pub events: Vec<events::Fetched>,
+ /// Commands to progress [`FetchState`].
+ pub effects: Vec<effects::Fetched>,
+ /// Effects that can be performed by the rest of the system.
+ pub commands: Vec<commands::Fetched>,
+}
+
+impl FetchedResult {
+ fn unexpected(&mut self, node: NodeId, rid: RepoId) {
+ self.events
+ .push(events::Fetched::UnexpectedResult { node, rid });
+ }
+
+ fn notify(&mut self, from: NodeId, rid: RepoId, result: node::FetchResult) {
+ self.effects
+ .push(effects::Fetched::Notify { from, rid, result })
+ }
+
+ fn dequeue_fetches(&mut self) {
+ self.commands.push(commands::Fetched::DequeueFetches);
+ }
+
+ fn disconnect(&mut self, node: NodeId, reason: String) {
+ self.effects
+ .push(effects::Fetched::Disconnect { node, reason })
+ }
+
+ fn announce(&mut self, rid: RepoId, doc: DocAt, namespaces: HashSet<NodeId>) {
+ self.effects.push(effects::Fetched::Announce {
+ rid,
+ doc,
+ namespaces,
+ })
+ }
+
+ fn public_repo(&mut self, rid: RepoId) {
+ self.events.push(events::Fetched::PublicRepo { rid });
+ }
+
+ fn refs_fetched(&mut self, node: NodeId, rid: RepoId, updated: Vec<RefUpdate>) {
+ self.events
+ .push(events::Fetched::RefsFetched { node, rid, updated });
+ }
+}
diff --git a/crates/radicle-protocol/src/fetcher/commands.rs b/crates/radicle-protocol/src/fetcher/commands.rs
new file mode 100644
index 00000000..19f352a7
--- /dev/null
+++ b/crates/radicle-protocol/src/fetcher/commands.rs
@@ -0,0 +1,58 @@
+use std::time;
+
+use nonempty::NonEmpty;
+use radicle::{node::NodeId, prelude::RepoId, storage::refs::RefsAt};
+
+/// Commands for transitioning the [`FetchState`].
+///
+/// [`FetchState`]: super::FetchState
+pub enum Command {
+ Fetch(Fetch),
+ Fetched(Fetched),
+}
+
+impl From<Fetch> for Command {
+ fn from(v: Fetch) -> Self {
+ Self::Fetch(v)
+ }
+}
+
+impl From<Fetched> for Command {
+ fn from(v: Fetched) -> Self {
+ Self::Fetched(v)
+ }
+}
+
+/// Command results that occur when a repository is being fetched.
+#[derive(Clone, Debug, PartialEq, Eq)]
+pub enum Fetch {
+ /// The repository should be queued for fetching.
+ Queue {
+ from: NodeId,
+ rid: RepoId,
+ refs_at: Vec<RefsAt>,
+ timeout: time::Duration,
+ },
+ /// The repository should be fetched, and we do not know the references that
+ /// are required for fetching.
+ Repository {
+ from: NodeId,
+ rid: RepoId,
+ timeout: time::Duration,
+ },
+ /// The repository should be fetched, and only the references stated should
+ /// be fetched.
+ RefsAt {
+ from: NodeId,
+ rid: RepoId,
+ refs_at: NonEmpty<RefsAt>,
+ timeout: time::Duration,
+ },
+}
+
+/// Command results that occur after a repository has been fetched.
+#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash)]
+pub enum Fetched {
+ DequeueFetches,
+ Fetched { from: NodeId, rid: RepoId },
+}
diff --git a/crates/radicle-protocol/src/fetcher/effects.rs b/crates/radicle-protocol/src/fetcher/effects.rs
new file mode 100644
index 00000000..11d06336
--- /dev/null
+++ b/crates/radicle-protocol/src/fetcher/effects.rs
@@ -0,0 +1,28 @@
+use std::collections::HashSet;
+
+use radicle::{identity::DocAt, node, node::NodeId, prelude::RepoId};
+
+/// Effects that should be performed after a repository has been fetched.
+#[derive(Clone, Debug, PartialEq, Eq)]
+pub enum Fetched {
+ /// Announce that the namespaces were fetched for this repository.
+ Announce {
+ rid: RepoId,
+ doc: DocAt,
+ namespaces: HashSet<NodeId>,
+ },
+ /// Notify listeners about the result of the fetch.
+ Notify {
+ from: NodeId,
+ rid: RepoId,
+ result: node::FetchResult,
+ },
+ /// The fetch failed, due to a timeout, so the [`NodeId`] should likely be
+ /// disconnected.
+ Disconnect {
+ node: NodeId,
+ // TODO(finto): this was a FetchError type is it ok to have it just as a
+ // String?
+ reason: String,
+ },
+}
diff --git a/crates/radicle-protocol/src/fetcher/events.rs b/crates/radicle-protocol/src/fetcher/events.rs
new file mode 100644
index 00000000..2b71b0a4
--- /dev/null
+++ b/crates/radicle-protocol/src/fetcher/events.rs
@@ -0,0 +1,30 @@
+use radicle::{node::NodeId, prelude::RepoId, storage::RefUpdate};
+
+use super::FetchingFor;
+
+/// Events that occur when a repository is being fetched.
+#[derive(Clone, Debug, PartialEq, Eq)]
+pub enum Fetch {
+ /// The repository is already being fetched.
+ AlreadyFetching { rid: RepoId, fetching: FetchingFor },
+ /// The capacity of the node has been reached.
+ CapacityReached,
+}
+
+/// Events that occur after a repository has been fetched.
+// TODO(finto): note to self a successful fetch should mark a seed as discovered
+#[derive(Clone, Debug, PartialEq, Eq)]
+pub enum Fetched {
+ /// There was no ongoing fetch for the given [`NodeId`] and [`RepoId`].
+ UnexpectedResult { node: NodeId, rid: RepoId },
+ /// The [`RepoId`] was fetched from the [`NodeId`] with the set of updated
+ /// references.
+ RefsFetched {
+ node: NodeId,
+ rid: RepoId,
+ updated: Vec<RefUpdate>,
+ },
+ // TODO(finto): this needs to be used to add inventory
+ /// The fetched repository was a public repository.
+ PublicRepo { rid: RepoId },
+}
diff --git a/crates/radicle-protocol/src/lib.rs b/crates/radicle-protocol/src/lib.rs
index a54b764c..8934ff45 100644
--- a/crates/radicle-protocol/src/lib.rs
+++ b/crates/radicle-protocol/src/lib.rs
@@ -5,6 +5,7 @@ pub mod wire;
pub mod worker;
pub mod connections;
+pub mod fetcher;
pub mod tasks;
/// Peer-to-peer protocol version.
diff --git a/crates/radicle/src/node.rs b/crates/radicle/src/node.rs
index 87418e72..e48c8214 100644
--- a/crates/radicle/src/node.rs
+++ b/crates/radicle/src/node.rs
@@ -904,7 +904,7 @@ impl From<Vec<Seed>> for Seeds {
}
}
-#[derive(Clone, Debug, Serialize, Deserialize)]
+#[derive(Clone, Debug, Serialize, Deserialize, PartialEq, Eq)]
#[serde(tag = "status", rename_all = "camelCase")]
#[cfg_attr(feature = "schemars", derive(schemars::JsonSchema))]
pub enum FetchResult {
Exit code: 0
shell: 'cargo --version rustc --version cargo fmt --check cargo clippy --all-targets --workspace -- --deny warnings cargo build --all-targets --workspace cargo doc --workspace --no-deps cargo test --workspace --no-fail-fast '
Commands:
$ podman run --name 3b386d3c-cd9e-471c-9b6c-b1ec80313805 -v /opt/radcis/ci.rad.levitte.org/cci/state/3b386d3c-cd9e-471c-9b6c-b1ec80313805/s:/3b386d3c-cd9e-471c-9b6c-b1ec80313805/s:ro -v /opt/radcis/ci.rad.levitte.org/cci/state/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w:/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w -w /3b386d3c-cd9e-471c-9b6c-b1ec80313805/w -v /opt/radcis/ci.rad.levitte.org/.radicle:/${id}/.radicle:ro -e RAD_HOME=/${id}/.radicle rust:bookworm bash /3b386d3c-cd9e-471c-9b6c-b1ec80313805/s/script.sh
+ cargo --version
info: syncing channel updates for '1.88-x86_64-unknown-linux-gnu'
info: latest update on 2025-06-26, rust version 1.88.0 (6b00bc388 2025-06-23)
info: downloading component 'cargo'
info: downloading component 'clippy'
info: downloading component 'rust-docs'
info: downloading component 'rust-src'
info: downloading component 'rust-std'
info: downloading component 'rustc'
info: downloading component 'rustfmt'
info: installing component 'cargo'
info: installing component 'clippy'
info: installing component 'rust-docs'
info: installing component 'rust-src'
info: installing component 'rust-std'
info: installing component 'rustc'
info: installing component 'rustfmt'
cargo 1.88.0 (873a06493 2025-05-10)
+ rustc --version
rustc 1.88.0 (6b00bc388 2025-06-23)
+ cargo fmt --check
+ cargo clippy --all-targets --workspace -- --deny warnings
Updating crates.io index
Downloading crates ...
Downloaded cipher v0.4.4
Downloaded env_logger v0.11.8
Downloaded cyphernet v0.5.2
Downloaded pin-project-lite v0.2.16
Downloaded ryu v1.0.17
Downloaded ref-cast-impl v1.0.24
Downloaded regex-automata v0.4.9
Downloaded memchr v2.7.2
Downloaded pbkdf2 v0.12.2
Downloaded tinyvec_macros v0.1.1
Downloaded errno v0.3.13
Downloaded parking_lot_core v0.9.9
Downloaded serde_derive v1.0.219
Downloaded scopeguard v1.2.0
Downloaded same-file v1.0.6
Downloaded flate2 v1.1.1
Downloaded crypto-common v0.1.6
Downloaded crc32fast v1.4.0
Downloaded ascii v1.1.0
Downloaded socket2 v0.5.7
Downloaded gix-pack v0.56.0
Downloaded serde_derive_internals v0.29.1
Downloaded generic-array v0.14.7
Downloaded arc-swap v1.7.1
Downloaded streaming-iterator v0.1.9
Downloaded signal-hook-mio v0.2.4
Downloaded ff v0.13.0
Downloaded crossbeam-utils v0.8.19
Downloaded regex v1.11.1
Downloaded url v2.5.4
Downloaded signal-hook-registry v1.4.5
Downloaded fraction v0.15.3
Downloaded ecdsa v0.16.9
Downloaded cypheraddr v0.4.0
Downloaded gix-validate v0.9.4
Downloaded salsa20 v0.10.2
Downloaded systemd-journal-logger v2.2.2
Downloaded siphasher v1.0.1
Downloaded serde v1.0.219
Downloaded regex-syntax v0.6.29
Downloaded subtle v2.5.0
Downloaded phf_shared v0.11.3
Downloaded group v0.13.0
Downloaded litemap v0.7.5
Downloaded icu_normalizer v1.5.0
Downloaded synstructure v0.13.1
Downloaded icu_properties v1.5.1
Downloaded jobserver v0.1.31
Downloaded matchers v0.1.0
Downloaded log v0.4.27
Downloaded num v0.4.3
Downloaded vsimd v0.8.0
Downloaded quote v1.0.36
Downloaded jsonschema v0.30.0
Downloaded normalize-line-endings v0.3.0
Downloaded ghash v0.5.1
Downloaded zerovec-derive v0.10.3
Downloaded zerofrom v0.1.6
Downloaded gix-negotiate v0.17.0
Downloaded gix-utils v0.1.14
Downloaded home v0.5.9
Downloaded hmac v0.12.1
Downloaded idna_adapter v1.2.0
Downloaded localtime v1.3.1
Downloaded zerofrom-derive v0.1.6
Downloaded gix-sec v0.10.12
Downloaded yoke v0.7.5
Downloaded zerovec v0.10.4
Downloaded gix-config-value v0.14.12
Downloaded thread_local v1.1.9
Downloaded gix-refspec v0.27.0
Downloaded universal-hash v0.5.1
Downloaded libm v0.2.8
Downloaded lock_api v0.4.11
Downloaded gix-prompt v0.9.1
Downloaded idna v1.0.3
Downloaded gix-tempfile v15.0.0
Downloaded icu_locid v1.5.0
Downloaded gix-ref v0.49.1
Downloaded tinystr v0.7.6
Downloaded icu_collections v1.5.0
Downloaded gix-quote v0.4.15
Downloaded gix-hashtable v0.6.0
Downloaded tinyvec v1.6.0
Downloaded multibase v0.9.1
Downloaded unicode-normalization v0.1.23
Downloaded nonempty v0.9.0
Downloaded noise-framework v0.4.0
Downloaded syn v2.0.89
Downloaded thiserror-impl v2.0.12
Downloaded unicode-width v0.1.11
Downloaded nu-ansi-term v0.46.0
Downloaded regex-syntax v0.8.5
Downloaded unicode-ident v1.0.12
Downloaded gix-transport v0.44.0
Downloaded litrs v0.4.1
Downloaded miniz_oxide v0.8.8
Downloaded mio v1.0.4
Downloaded tree-sitter-go v0.23.4
Downloaded unicode-segmentation v1.11.0
Downloaded mio v0.8.11
Downloaded tree-sitter v0.24.4
Downloaded sha3 v0.10.8
Downloaded winnow v0.6.26
Downloaded git2 v0.19.0
Downloaded vcpkg v0.2.15
Downloaded tree-sitter-md v0.3.2
Downloaded tree-sitter-rust v0.23.2
Downloaded inquire v0.7.5
Downloaded tree-sitter-bash v0.23.3
Downloaded indexmap v2.2.6
Downloaded tree-sitter-c v0.23.2
Downloaded thiserror v1.0.69
Downloaded num-complex v0.4.6
Downloaded libc v0.2.174
Downloaded zeroize v1.7.0
Downloaded icu_locid_transform v1.5.0
Downloaded tracing-subscriber v0.3.19
Downloaded test-log-macros v0.2.18
Downloaded test-log v0.2.18
Downloaded num-integer v0.1.46
Downloaded gix-traverse v0.43.1
Downloaded gix-trace v0.1.12
Downloaded gix-revwalk v0.17.0
Downloaded version_check v0.9.4
Downloaded timeago v0.4.2
Downloaded tree-sitter-typescript v0.23.2
Downloaded gix-chunk v0.4.11
Downloaded gix-actor v0.33.2
Downloaded walkdir v2.5.0
Downloaded nonempty v0.5.0
Downloaded netservices v0.8.0
Downloaded tree-sitter-css v0.23.1
Downloaded syn v1.0.109
Downloaded gix-path v0.10.15
Downloaded gix-lock v15.0.1
Downloaded git-ref-format-macro v0.3.1
Downloaded gix-packetline v0.18.4
Downloaded gix-hash v0.15.1
Downloaded icu_provider v1.5.0
Downloaded libgit2-sys v0.17.0+1.8.1
Downloaded icu_locid_transform_data v1.5.1
Downloaded gix-fs v0.12.1
Downloaded io-reactor v0.5.2
Downloaded inout v0.1.3
Downloaded icu_provider_macros v1.5.0
Downloaded num-bigint-dig v0.8.4
Downloaded serde_json v1.0.140
Downloaded gix-revision v0.31.1
Downloaded gix-features v0.39.1
Downloaded typenum v1.17.0
Downloaded iana-time-zone v0.1.60
Downloaded writeable v0.5.5
Downloaded write16 v1.0.0
Downloaded tar v0.4.40
Downloaded tree-sitter-language v0.1.2
Downloaded gix-odb v0.66.0
Downloaded zerocopy v0.7.35
Downloaded uuid v1.16.0
Downloaded gix-protocol v0.47.0
Downloaded linux-raw-sys v0.4.13
Downloaded tempfile v3.10.1
Downloaded gix-credentials v0.26.0
Downloaded git-ref-format-core v0.3.1
Downloaded tree-sitter-ruby v0.23.1
Downloaded gix-url v0.28.2
Downloaded unicode-display-width v0.3.0
Downloaded gix-commitgraph v0.25.1
Downloaded gix-command v0.4.1
Downloaded typeid v1.0.3
Downloaded tree-sitter-json v0.24.8
Downloaded tree-sitter-html v0.23.2
Downloaded itoa v1.0.11
Downloaded yansi v0.5.1
Downloaded num-rational v0.4.2
Downloaded gix-diff v0.49.0
Downloaded tracing v0.1.41
Downloaded xattr v1.3.1
Downloaded newline-converter v0.3.0
Downloaded yoke-derive v0.7.5
Downloaded num-iter v0.1.45
Downloaded libz-sys v1.1.16
Downloaded lexopt v0.3.0
Downloaded ssh-key v0.6.6
Downloaded gix-object v0.46.1
Downloaded gix-date v0.9.4
Downloaded utf8_iter v1.0.4
Downloaded utf16_iter v1.0.5
Downloaded num-bigint v0.4.6
Downloaded tree-sitter-toml-ng v0.6.0
Downloaded tracing-log v0.2.0
Downloaded tracing-core v0.1.34
Downloaded jiff v0.2.1
Downloaded prodash v29.0.2
Downloaded gix-shallow v0.1.0
Downloaded git-ref-format v0.3.1
Downloaded uuid-simd v0.8.0
Downloaded utf8parse v0.2.1
Downloaded thiserror v2.0.12
Downloaded num-cmp v0.1.0
Downloaded icu_properties_data v1.5.1
Downloaded rand v0.8.5
Downloaded pem-rfc7468 v0.7.0
Downloaded thiserror-impl v1.0.69
Downloaded linux-raw-sys v0.9.4
Downloaded memmap2 v0.9.4
Downloaded maybe-async v0.2.10
Downloaded keccak v0.1.5
Downloaded sqlite v0.32.0
Downloaded spin v0.9.8
Downloaded smallvec v1.13.2
Downloaded hashbrown v0.14.3
Downloaded spki v0.7.3
Downloaded signal-hook v0.3.18
Downloaded schemars v1.0.4
Downloaded sqlite3-src v0.5.1
Downloaded rsa v0.9.6
Downloaded poly1305 v0.8.0
Downloaded bstr v1.9.1
Downloaded bloomy v1.2.0
Downloaded lazy_static v1.5.0
Downloaded polyval v0.6.2
Downloaded schemars_derive v1.0.4
Downloaded proc-macro-error v1.0.4
Downloaded cc v1.2.2
Downloaded siphasher v0.3.11
Downloaded sha1_smol v1.0.0
Downloaded qcheck v1.0.0
Downloaded proc-macro-error-attr v1.0.4
Downloaded phf v0.11.3
Downloaded pkcs1 v0.7.5
Downloaded radicle-std-ext v0.1.0
Downloaded radicle-git-ext v0.8.1
Downloaded primeorder v0.13.6
Downloaded stable_deref_trait v1.2.0
Downloaded ppv-lite86 v0.2.17
Downloaded icu_normalizer_data v1.5.1
Downloaded ssh-encoding v0.2.0
Downloaded serde-untagged v0.1.7
Downloaded sem_safe v0.2.0
Downloaded scrypt v0.11.0
Downloaded rand_chacha v0.3.1
Downloaded pkcs8 v0.10.2
Downloaded fxhash v0.2.1
Downloaded crossbeam-channel v0.5.15
Downloaded chrono v0.4.38
Downloaded bytes v1.10.1
Downloaded block-padding v0.3.3
Downloaded block-buffer v0.10.4
Downloaded bitflags v1.3.2
Downloaded sqlite3-sys v0.15.2
Downloaded similar v2.5.0
Downloaded signature v2.2.0
Downloaded signature v1.6.4
Downloaded shell-words v1.1.0
Downloaded rfc6979 v0.4.0
Downloaded regex-automata v0.1.10
Downloaded fastrand v2.1.0
Downloaded chacha20poly1305 v0.10.1
Downloaded cbc v0.1.2
Downloaded blowfish v0.9.1
Downloaded qcheck-macros v1.0.0
Downloaded crypto-bigint v0.5.5
Downloaded crossterm v0.29.0
Downloaded crossterm v0.25.0
Downloaded bitflags v2.9.1
Downloaded borrow-or-share v0.2.2
Downloaded bytecount v0.6.8
Downloaded convert_case v0.7.1
Downloaded colored v2.1.0
Downloaded bytesize v2.0.1
Downloaded ssh-cipher v0.2.0
Downloaded snapbox-macros v0.3.8
Downloaded colorchoice v1.0.0
Downloaded cfg-if v1.0.0
Downloaded byteorder v1.5.0
Downloaded dyn-clone v1.0.17
Downloaded document-features v0.2.11
Downloaded cyphergraphy v0.3.0
Downloaded ctr v0.9.2
Downloaded ct-codecs v1.1.1
Downloaded cpufeatures v0.2.12
Downloaded const-oid v0.9.6
Downloaded fancy-regex v0.14.0
Downloaded env_filter v0.1.3
Downloaded ed25519 v1.5.3
Downloaded digest v0.10.7
Downloaded tree-sitter-highlight v0.24.4
Downloaded derive_more-impl v2.0.1
Downloaded derive_more v2.0.1
Downloaded shlex v1.3.0
Downloaded proc-macro2 v1.0.92
Downloaded popol v3.0.0
Downloaded faster-hex v0.9.0
Downloaded erased-serde v0.4.6
Downloaded email_address v0.2.9
Downloaded either v1.11.0
Downloaded data-encoding-macro-internal v0.1.12
Downloaded data-encoding v2.5.0
Downloaded sharded-slab v0.1.7
Downloaded sha2 v0.10.8
Downloaded radicle-surf v0.22.0
Downloaded fast-glob v0.3.3
Downloaded equivalent v1.0.1
Downloaded elliptic-curve v0.13.8
Downloaded ec25519 v0.1.0
Downloaded displaydoc v0.2.5
Downloaded diff v0.1.13
Downloaded socks5-client v0.4.1
Downloaded sec1 v0.7.3
Downloaded rustix v1.0.7
Downloaded referencing v0.30.0
Downloaded pkg-config v0.3.30
Downloaded emojis v0.6.4
Downloaded data-encoding-macro v0.1.14
Downloaded aes v0.8.4
Downloaded fluent-uri v0.3.2
Downloaded der v0.7.9
Downloaded form_urlencoded v1.2.1
Downloaded snapbox v0.4.17
Downloaded signals_receipts v0.2.0
Downloaded rustix v0.38.34
Downloaded base16ct v0.2.0
Downloaded anyhow v1.0.82
Downloaded anstyle-query v1.0.2
Downloaded aho-corasick v1.1.3
Downloaded base-x v0.2.11
Downloaded base64ct v1.6.0
Downloaded autocfg v1.2.0
Downloaded base64 v0.21.7
Downloaded p256 v0.13.2
Downloaded bit-vec v0.8.0
Downloaded aead v0.5.2
Downloaded base32 v0.4.0
Downloaded p384 v0.13.0
Downloaded escargot v0.5.10
Downloaded base64 v0.22.1
Downloaded rand_core v0.6.4
Downloaded parking_lot v0.12.3
Downloaded p521 v0.13.3
Downloaded once_cell v1.21.3
Downloaded overload v0.1.1
Downloaded num-traits v0.2.19
Downloaded anstyle v1.0.6
Downloaded getrandom v0.2.15
Downloaded filetime v0.2.23
Downloaded bcrypt-pbkdf v0.10.0
Downloaded amplify_derive v4.0.0
Downloaded outref v0.5.2
Downloaded opaque-debug v0.3.1
Downloaded anstream v0.6.13
Downloaded amplify v4.6.0
Downloaded ref-cast v1.0.24
Downloaded pretty_assertions v1.4.0
Downloaded base64 v0.13.1
Downloaded adler2 v2.0.0
Downloaded percent-encoding v2.3.1
Downloaded bit-set v0.8.0
Downloaded amplify_syn v2.0.1
Downloaded aes-gcm v0.10.3
Downloaded anstyle-parse v0.2.3
Downloaded amplify_num v0.5.2
Downloaded ahash v0.8.11
Downloaded chacha20 v0.9.1
Downloaded tree-sitter-python v0.23.4
Compiling libc v0.2.174
Compiling proc-macro2 v1.0.92
Compiling unicode-ident v1.0.12
Checking cfg-if v1.0.0
Compiling shlex v1.3.0
Compiling version_check v0.9.4
Compiling serde v1.0.219
Checking memchr v2.7.2
Compiling quote v1.0.36
Compiling syn v2.0.89
Compiling jobserver v0.1.31
Compiling autocfg v1.2.0
Checking getrandom v0.2.15
Compiling cc v1.2.2
Checking log v0.4.27
Checking smallvec v1.13.2
Checking aho-corasick v1.1.3
Checking regex-syntax v0.8.5
Compiling typenum v1.17.0
Compiling generic-array v0.14.7
Checking regex-automata v0.4.9
Checking rand_core v0.6.4
Checking fastrand v2.1.0
Checking bitflags v2.9.1
Compiling synstructure v0.13.1
Checking crypto-common v0.1.6
Compiling lock_api v0.4.11
Compiling parking_lot_core v0.9.9
Checking bstr v1.9.1
Checking scopeguard v1.2.0
Checking stable_deref_trait v1.2.0
Checking subtle v2.5.0
Checking once_cell v1.21.3
Checking parking_lot v0.12.3
Checking tinyvec_macros v0.1.1
Compiling syn v1.0.109
Checking tinyvec v1.6.0
Checking zeroize v1.7.0
Compiling serde_derive v1.0.219
Compiling zerofrom-derive v0.1.6
Compiling yoke-derive v0.7.5
Compiling zerovec-derive v0.10.3
Checking zerofrom v0.1.6
Checking yoke v0.7.5
Compiling displaydoc v0.2.5
Checking zerovec v0.10.4
Checking unicode-normalization v0.1.23
Checking cpufeatures v0.2.12
Checking tinystr v0.7.6
Compiling crc32fast v1.4.0
Checking litemap v0.7.5
Compiling thiserror v2.0.12
Checking writeable v0.5.5
Compiling icu_locid_transform_data v1.5.1
Checking icu_locid v1.5.0
Compiling thiserror-impl v2.0.12
Compiling icu_provider_macros v1.5.0
Checking block-padding v0.3.3
Compiling icu_properties_data v1.5.1
Checking inout v0.1.3
Checking icu_provider v1.5.0
Checking block-buffer v0.10.4
Checking hashbrown v0.14.3
Checking itoa v1.0.11
Compiling pkg-config v0.3.30
Compiling icu_normalizer_data v1.5.1
Checking digest v0.10.7
Checking icu_locid_transform v1.5.0
Checking cipher v0.4.4
Checking icu_collections v1.5.0
Checking utf16_iter v1.0.5
Compiling thiserror v1.0.69
Checking utf8_iter v1.0.4
Checking write16 v1.0.0
Compiling thiserror-impl v1.0.69
Checking percent-encoding v2.3.1
Checking icu_properties v1.5.1
Compiling rustix v0.38.34
Checking linux-raw-sys v0.4.13
Checking sha2 v0.10.8
Checking form_urlencoded v1.2.1
Checking universal-hash v0.5.1
Checking opaque-debug v0.3.1
Compiling vcpkg v0.2.15
Checking icu_normalizer v1.5.0
Compiling amplify_syn v2.0.1
Compiling libz-sys v1.1.16
Checking idna_adapter v1.2.0
Checking idna v1.0.3
Compiling data-encoding v2.5.0
Checking gix-trace v0.1.12
Compiling amplify_derive v4.0.0
Checking url v2.5.4
Checking tempfile v3.10.1
Checking amplify_num v0.5.2
Compiling data-encoding-macro-internal v0.1.12
Checking signature v1.6.4
Checking ascii v1.1.0
Checking data-encoding-macro v0.1.14
Checking ed25519 v1.5.3
Compiling libgit2-sys v0.17.0+1.8.1
Checking faster-hex v0.9.0
Checking aead v0.5.2
Compiling num-traits v0.2.19
Compiling proc-macro-error-attr v1.0.4
Checking ct-codecs v1.1.1
Checking base-x v0.2.11
Checking byteorder v1.5.0
Checking ec25519 v0.1.0
Checking multibase v0.9.1
Checking amplify v4.6.0
Checking poly1305 v0.8.0
Checking chacha20 v0.9.1
Checking gix-utils v0.1.14
Compiling proc-macro-error v1.0.4
Checking adler2 v2.0.0
Checking miniz_oxide v0.8.8
Checking cyphergraphy v0.3.0
Checking gix-hash v0.15.1
Checking same-file v1.0.6
Compiling crossbeam-utils v0.8.19
Checking keccak v0.1.5
Checking sha3 v0.10.8
Checking flate2 v1.1.1
Checking walkdir v2.5.0
Compiling git-ref-format-core v0.3.1
Checking polyval v0.6.2
Checking hmac v0.12.1
Compiling sqlite3-src v0.5.1
Checking prodash v29.0.2
Checking ppv-lite86 v0.2.17
Checking base32 v0.4.0
Checking sha1_smol v1.0.0
Checking base64ct v1.6.0
Checking equivalent v1.0.1
Compiling serde_json v1.0.140
Checking indexmap v2.2.6
Checking pem-rfc7468 v0.7.0
Checking gix-features v0.39.1
Checking cypheraddr v0.4.0
Checking rand_chacha v0.3.1
Compiling git-ref-format-macro v0.3.1
Checking pbkdf2 v0.12.2
Checking ghash v0.5.1
Checking chacha20poly1305 v0.10.1
Checking aes v0.8.4
Checking ctr v0.9.2
Checking ryu v1.0.17
Checking aes-gcm v0.10.3
Checking git-ref-format v0.3.1
Checking noise-framework v0.4.0
Checking crossbeam-channel v0.5.15
Checking rand v0.8.5
Checking socks5-client v0.4.1
Checking ssh-encoding v0.2.0
Checking blowfish v0.9.1
Checking cbc v0.1.2
Checking radicle-std-ext v0.1.0
Compiling ref-cast v1.0.24
Checking home v0.5.9
Checking gix-path v0.10.15
Checking ssh-cipher v0.2.0
Checking bcrypt-pbkdf v0.10.0
Checking cyphernet v0.5.2
Compiling ref-cast-impl v1.0.24
Checking signature v2.2.0
Checking ssh-key v0.6.6
Checking qcheck v1.0.0
Checking radicle-ssh v0.9.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-ssh)
Checking lazy_static v1.5.0
Compiling typeid v1.0.3
Checking dyn-clone v1.0.17
Checking siphasher v1.0.1
Checking nonempty v0.9.0
Compiling serde_derive_internals v0.29.1
Checking radicle-dag v0.10.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-dag)
Checking erased-serde v0.4.6
Checking jiff v0.2.1
Compiling schemars_derive v1.0.4
Checking iana-time-zone v0.1.60
Checking chrono v0.4.38
Checking gix-date v0.9.4
Checking schemars v1.0.4
Checking serde-untagged v0.1.7
Checking colored v2.1.0
Checking bytesize v2.0.1
Checking localtime v1.3.1
Checking winnow v0.6.26
Checking base64 v0.21.7
Checking tree-sitter-language v0.1.2
Checking fast-glob v0.3.3
Checking gix-hashtable v0.6.0
Checking gix-validate v0.9.4
Checking anstyle-query v1.0.2
Checking memmap2 v0.9.4
Compiling rustix v1.0.7
Compiling anyhow v1.0.82
Checking gix-actor v0.33.2
Checking gix-object v0.46.1
Checking gix-chunk v0.4.11
Checking linux-raw-sys v0.9.4
Checking gix-commitgraph v0.25.1
Checking gix-revwalk v0.17.0
Checking gix-fs v0.12.1
Checking errno v0.3.13
Checking sem_safe v0.2.0
Checking signals_receipts v0.2.0
Checking gix-tempfile v15.0.0
Compiling signal-hook v0.3.18
Checking signal-hook-registry v1.4.5
Checking shell-words v1.1.0
Checking gix-command v0.4.1
Checking radicle-signals v0.11.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-signals)
Compiling tree-sitter v0.24.4
Checking mio v1.0.4
Checking mio v0.8.11
Compiling unicode-segmentation v1.11.0
Checking utf8parse v0.2.1
Checking anstyle-parse v0.2.3
Compiling convert_case v0.7.1
Checking signal-hook-mio v0.2.4
Checking gix-lock v15.0.1
Checking gix-url v0.28.2
Checking gix-config-value v0.14.12
Checking gix-quote v0.4.15
Checking regex v1.11.1
Checking gix-sec v0.10.12
Checking anstyle v1.0.6
Checking colorchoice v1.0.0
Checking anstream v0.6.13
Checking sqlite3-sys v0.15.2
Checking gix-prompt v0.9.1
Checking sqlite v0.32.0
Compiling xattr v1.3.1
Compiling derive_more-impl v2.0.1
Compiling filetime v0.2.23
Checking gix-traverse v0.43.1
Checking gix-revision v0.31.1
Checking gix-diff v0.49.0
Checking gix-packetline v0.18.4
Checking lexopt v0.3.0
Compiling litrs v0.4.1
Checking bitflags v1.3.2
Checking derive_more v2.0.1
Checking crossterm v0.25.0
Checking gix-transport v0.44.0
Compiling document-features v0.2.11
Checking gix-pack v0.56.0
Checking gix-refspec v0.27.0
Compiling tar v0.4.40
Checking gix-credentials v0.26.0
Checking newline-converter v0.3.0
Checking gix-ref v0.49.1
Checking gix-shallow v0.1.0
Checking gix-negotiate v0.17.0
Checking fxhash v0.2.1
Compiling maybe-async v0.2.10
Checking streaming-iterator v0.1.9
Checking arc-swap v1.7.1
Checking unicode-width v0.1.11
Checking inquire v0.7.5
Checking gix-odb v0.66.0
Checking gix-protocol v0.47.0
Compiling radicle-surf v0.22.0
Checking crossterm v0.29.0
Checking unicode-display-width v0.3.0
Compiling tree-sitter-python v0.23.4
Compiling tree-sitter-css v0.23.1
Compiling tree-sitter-c v0.23.2
Compiling tree-sitter-toml-ng v0.6.0
Compiling tree-sitter-ruby v0.23.1
Compiling tree-sitter-bash v0.23.3
Compiling tree-sitter-rust v0.23.2
Compiling tree-sitter-typescript v0.23.2
Compiling tree-sitter-json v0.24.8
Compiling tree-sitter-go v0.23.4
Compiling tree-sitter-html v0.23.2
Compiling tree-sitter-md v0.3.2
Checking either v1.11.0
Checking snapbox-macros v0.3.8
Checking salsa20 v0.10.2
Checking nonempty v0.5.0
Checking similar v2.5.0
Checking base64 v0.13.1
Compiling radicle-cli v0.14.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-cli)
Checking normalize-line-endings v0.3.0
Checking siphasher v0.3.11
Checking snapbox v0.4.17
Checking bloomy v1.2.0
Checking scrypt v0.11.0
Checking tree-sitter-highlight v0.24.4
Checking systemd-journal-logger v2.2.2
Checking popol v3.0.0
Checking bytes v1.10.1
Checking timeago v0.4.2
Checking io-reactor v0.5.2
Checking socket2 v0.5.7
Checking diff v0.1.13
Checking yansi v0.5.1
Compiling radicle-node v0.12.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-node)
Checking netservices v0.8.0
Checking pretty_assertions v1.4.0
Checking radicle-systemd v0.9.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-systemd)
Checking num-integer v0.1.46
Compiling escargot v0.5.10
Compiling qcheck-macros v1.0.0
Checking num-bigint v0.4.6
Compiling ahash v0.8.11
Compiling radicle-remote-helper v0.11.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-remote-helper)
Checking num-iter v0.1.45
Checking num-complex v0.4.6
Checking env_filter v0.1.3
Checking num-rational v0.4.2
Checking bit-vec v0.8.0
Checking zerocopy v0.7.35
Checking borrow-or-share v0.2.2
Checking num v0.4.3
Checking fluent-uri v0.3.2
Checking bit-set v0.8.0
Checking env_logger v0.11.8
Checking phf_shared v0.11.3
Compiling test-log-macros v0.2.18
Checking uuid v1.16.0
Checking outref v0.5.2
Checking vsimd v0.8.0
Checking referencing v0.30.0
Checking phf v0.11.3
Checking uuid-simd v0.8.0
Checking test-log v0.2.18
Checking fancy-regex v0.14.0
Checking fraction v0.15.3
Checking email_address v0.2.9
Checking base64 v0.22.1
Checking num-cmp v0.1.0
Checking bytecount v0.6.8
Checking emojis v0.6.4
Checking jsonschema v0.30.0
Checking git2 v0.19.0
Checking radicle-git-ext v0.8.1
Checking radicle-term v0.13.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-term)
Checking radicle-crypto v0.12.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-crypto)
Checking radicle-cob v0.14.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-cob)
Checking radicle v0.16.1 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle)
Checking radicle-fetch v0.12.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-fetch)
Checking radicle-cli-test v0.11.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-cli-test)
Checking radicle-schemars v0.1.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-schemars)
Checking radicle-protocol v0.1.0 (/3b386d3c-cd9e-471c-9b6c-b1ec80313805/w/crates/radicle-protocol)
error: variables can be used directly in the `format!` string
--> crates/radicle-protocol/src/tasks.rs:396:9
|
396 | / assert_eq!(
397 | | got.len(),
398 | | expected.len(),
399 | | "extra task(s) emitted: {:?}",
400 | | got
401 | | );
| |_________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
= note: `-D clippy::uninlined-format-args` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(clippy::uninlined_format_args)]`
error: variables can be used directly in the `format!` string
--> crates/radicle-protocol/src/tasks.rs:408:9
|
408 | / assert_eq!(
409 | | got.len(),
410 | | expected.len(),
411 | | "extra timer(s) emitted: {:?}",
412 | | got
413 | | );
| |_________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
error: could not compile `radicle-protocol` (lib test) due to 2 previous errors
warning: build failed, waiting for other jobs to finish...
Exit code: 101
{
"response": "finished",
"result": "failure"
}