rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5 heartwood398a5e87781ea7811fc11112976ee8e09af800a5
{
"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": "Created",
"patch": {
"id": "e2f13900aae792b1f8985b432842ab7ccc91df29",
"author": {
"id": "did:key:z6MkkfM3tPXNPrPevKr3uSiQtHPuwnNhu2yUVjgd2jXVsVz5",
"alias": "sebastinez"
},
"title": "httpd: Add apiVersion to root handler and node information",
"state": {
"status": "merged",
"conflicts": []
},
"before": "0b816d5c8662df961da19e1faabc126a9e7b536f",
"after": "398a5e87781ea7811fc11112976ee8e09af800a5",
"commits": [
"398a5e87781ea7811fc11112976ee8e09af800a5"
],
"target": "6cfed884bf37cba1e0d8e97fa8b0e94df4a04b1f",
"labels": [],
"assignees": [],
"revisions": [
{
"id": "e2f13900aae792b1f8985b432842ab7ccc91df29",
"author": {
"id": "did:key:z6MkkfM3tPXNPrPevKr3uSiQtHPuwnNhu2yUVjgd2jXVsVz5",
"alias": "sebastinez"
},
"description": "This will help consumers of the httpd to check if they are on the right\nversion of the API",
"base": "0b816d5c8662df961da19e1faabc126a9e7b536f",
"oid": "c54c1671326ecc6332693d17cf4eb5e232e244c3",
"timestamp": 1714399055
},
{
"id": "4d9c07061c9b66117aafbe5bc8e77cbfab4e56a4",
"author": {
"id": "did:key:z6MkkfM3tPXNPrPevKr3uSiQtHPuwnNhu2yUVjgd2jXVsVz5",
"alias": "sebastinez"
},
"description": "Remove apiVersion from `/node` endpoint",
"base": "0b816d5c8662df961da19e1faabc126a9e7b536f",
"oid": "398a5e87781ea7811fc11112976ee8e09af800a5",
"timestamp": 1714646987
},
{
"id": "22d13e9195cbe7563c7597767573de3f4ec070fb",
"author": {
"id": "did:key:z6MkkfM3tPXNPrPevKr3uSiQtHPuwnNhu2yUVjgd2jXVsVz5",
"alias": "sebastinez"
},
"description": "Rebase.",
"base": "d04d9d7d1fb0329b62673ee9ec25b1a2081316ee",
"oid": "5ffbf7545fa9c9aa2f9f988c78960f8b794d036d",
"timestamp": 1714648144
}
]
}
}
{
"response": "triggered",
"run_id": {
"id": "169bbce4-cdbc-4ecb-b755-cd42da430a9b"
},
"info_url": "https://cci.rad.levitte.org//169bbce4-cdbc-4ecb-b755-cd42da430a9b.html"
}
Started at: 2025-10-21 18:58:24.596497+02:00
Commands:
$ rad clone rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5 .
✓ Creating checkout in ./...
✓ Remote cloudhead@z6MksFqXN3Yhqk8pTJdUGLwATkRfQvwZXPqR2qMEhbS9wzpT added
✓ Remote-tracking branch cloudhead@z6MksFqXN3Yhqk8pTJdUGLwATkRfQvwZXPqR2qMEhbS9wzpT/master created for z6MksFqXN3Yhqk8pTJdUGLwATkRfQvwZXPqR2qMEhbS9wzpT
✓ Remote cloudhead@z6MktaNvN1KVFMkSRAiN4qK5yvX1zuEEaseeX5sffhzPZRZW added
✓ Remote-tracking branch cloudhead@z6MktaNvN1KVFMkSRAiN4qK5yvX1zuEEaseeX5sffhzPZRZW/master created for z6MktaNvN1KVFMkSRAiN4qK5yvX1zuEEaseeX5sffhzPZRZW
✓ Remote fintohaps@z6MkireRatUThvd3qzfKht1S44wpm4FEWSSa4PRMTSQZ3voM added
✓ Remote-tracking branch fintohaps@z6MkireRatUThvd3qzfKht1S44wpm4FEWSSa4PRMTSQZ3voM/master created for z6MkireRatUThvd3qzfKht1S44wpm4FEWSSa4PRMTSQZ3voM
✓ Remote erikli@z6MkgFq6z5fkF2hioLLSNu1zP2qEL1aHXHZzGH1FLFGAnBGz added
✓ Remote-tracking branch erikli@z6MkgFq6z5fkF2hioLLSNu1zP2qEL1aHXHZzGH1FLFGAnBGz/master created for z6MkgFq6z5fkF2hioLLSNu1zP2qEL1aHXHZzGH1FLFGAnBGz
✓ Remote lorenz@z6MkkPvBfjP4bQmco5Dm7UGsX2ruDBieEHi8n9DVJWX5sTEz added
✓ Remote-tracking branch lorenz@z6MkkPvBfjP4bQmco5Dm7UGsX2ruDBieEHi8n9DVJWX5sTEz/master created for z6MkkPvBfjP4bQmco5Dm7UGsX2ruDBieEHi8n9DVJWX5sTEz
✓ Repository successfully cloned under /opt/radcis/ci.rad.levitte.org/cci/state/169bbce4-cdbc-4ecb-b755-cd42da430a9b/w/
╭────────────────────────────────────╮
│ heartwood │
│ Radicle Heartwood Protocol & Stack │
│ 125 issues · 15 patches │
╰────────────────────────────────────╯
Run `cd ./.` to go to the repository directory.
Exit code: 0
$ rad patch checkout e2f13900aae792b1f8985b432842ab7ccc91df29
✓ Switched to branch patch/e2f1390 at revision 4d9c070
✓ Branch patch/e2f1390 setup to track rad/patches/e2f13900aae792b1f8985b432842ab7ccc91df29
Exit code: 0
$ git config advice.detachedHead false
Exit code: 0
$ git checkout 398a5e87781ea7811fc11112976ee8e09af800a5
HEAD is now at 398a5e87 httpd: Add apiVersion to root handler and node information
Exit code: 0
$ git show 398a5e87781ea7811fc11112976ee8e09af800a5
commit 398a5e87781ea7811fc11112976ee8e09af800a5
Author: Sebastian Martinez <me@sebastinez.dev>
Date: Mon Apr 29 15:57:33 2024 +0200
httpd: Add apiVersion to root handler and node information
This will help consumers of the httpd to check if they are on the right
version of the API
diff --git a/radicle-httpd/src/api.rs b/radicle-httpd/src/api.rs
index 498b052b..4ffd3da0 100644
--- a/radicle-httpd/src/api.rs
+++ b/radicle-httpd/src/api.rs
@@ -34,7 +34,9 @@ use crate::api::error::Error;
use crate::cache::Cache;
use crate::Options;
-pub const VERSION: &str = env!("RADICLE_VERSION");
+pub const RADICLE_VERSION: &str = env!("RADICLE_VERSION");
+// This version has to be updated on every breaking change to the radicle-httpd API.
+pub const API_VERSION: &str = "0.1.0";
/// Identifier for sessions
type SessionId = String;
diff --git a/radicle-httpd/src/api/v1.rs b/radicle-httpd/src/api/v1.rs
index 437cc715..3815091b 100644
--- a/radicle-httpd/src/api/v1.rs
+++ b/radicle-httpd/src/api/v1.rs
@@ -11,7 +11,7 @@ use axum::routing::get;
use axum::Router;
use serde_json::json;
-use crate::api::{Context, VERSION};
+use crate::api::{Context, API_VERSION, RADICLE_VERSION};
pub fn router(ctx: Context) -> Router {
let root_router = Router::new()
@@ -34,7 +34,8 @@ async fn root_handler(State(ctx): State<Context>) -> impl IntoResponse {
let response = json!({
"message": "Welcome!",
"service": "radicle-httpd",
- "version": format!("{}-{}", VERSION, env!("GIT_HEAD")),
+ "version": format!("{}-{}", RADICLE_VERSION, env!("GIT_HEAD")),
+ "apiVersion": API_VERSION,
"nid": ctx.profile.public_key,
"path": "/api/v1",
"links": [
diff --git a/radicle-httpd/src/api/v1/node.rs b/radicle-httpd/src/api/v1/node.rs
index 0181868d..2e42b587 100644
--- a/radicle-httpd/src/api/v1/node.rs
+++ b/radicle-httpd/src/api/v1/node.rs
@@ -12,7 +12,7 @@ use radicle::node::{policy, AliasStore, Handle, NodeId, DEFAULT_TIMEOUT};
use radicle::Node;
use crate::api::error::Error;
-use crate::api::{self, Context, PoliciesQuery, VERSION};
+use crate::api::{self, Context, PoliciesQuery, RADICLE_VERSION};
use crate::axum_extra::{Path, Query};
pub fn router(ctx: Context) -> Router {
@@ -47,7 +47,7 @@ async fn node_handler(State(ctx): State<Context>) -> impl IntoResponse {
};
let response = json!({
"id": node_id.to_string(),
- "version": format!("{}-{}", VERSION, env!("GIT_HEAD")),
+ "version": format!("{}-{}", RADICLE_VERSION, env!("GIT_HEAD")),
"config": config,
"state": node_state,
});
Exit code: 0
shell: 'cargo --version rustc --version cargo fmt --check cargo clippy --all-targets --workspace -- --deny clippy::all cargo build --all-targets --workspace cargo doc --workspace cargo test --workspace --no-fail-fast '
Commands:
$ podman run --name 169bbce4-cdbc-4ecb-b755-cd42da430a9b -v /opt/radcis/ci.rad.levitte.org/cci/state/169bbce4-cdbc-4ecb-b755-cd42da430a9b/s:/169bbce4-cdbc-4ecb-b755-cd42da430a9b/s:ro -v /opt/radcis/ci.rad.levitte.org/cci/state/169bbce4-cdbc-4ecb-b755-cd42da430a9b/w:/169bbce4-cdbc-4ecb-b755-cd42da430a9b/w -w /169bbce4-cdbc-4ecb-b755-cd42da430a9b/w -v /opt/radcis/ci.rad.levitte.org/.radicle:/${id}/.radicle:ro -e RAD_HOME=/${id}/.radicle rust:bookworm bash /169bbce4-cdbc-4ecb-b755-cd42da430a9b/s/script.sh
+ cargo --version
info: syncing channel updates for '1.77-x86_64-unknown-linux-gnu'
info: latest update on 2024-04-09, rust version 1.77.2 (25ef9e3d8 2024-04-09)
info: downloading component 'cargo'
info: downloading component 'rust-std'
info: downloading component 'rustc'
info: installing component 'cargo'
info: installing component 'rust-std'
info: installing component 'rustc'
cargo 1.77.2 (e52e36006 2024-03-26)
+ rustc --version
rustc 1.77.2 (25ef9e3d8 2024-04-09)
+ cargo fmt --check
error: 'cargo-fmt' is not installed for the toolchain '1.77-x86_64-unknown-linux-gnu'.
To install, run `rustup component add --toolchain 1.77-x86_64-unknown-linux-gnu rustfmt`
Exit code: 1
{
"response": "finished",
"result": "failure"
}