Radish alpha
r
Radicle CI broker
Radicle
Git (anonymous pull)
Log in to clone via SSH
fix: if no adapter is available, print error message, don't give up
Lars Wirzenius committed 2 years ago
commit 1c87d349efa2556005b5d41f05db8b704a883eb5
parent 9886cfd48b7e53b95120dc00dce4225b05df99e4
1 file changed +8 -9
modified src/bin/ci-broker.rs
@@ -91,17 +91,16 @@ fn fallible_main() -> Result<(), BrokerError> {
            let mut run = Run::default();
            if let Some(adapter) = broker.adapter(&rid) {
                adapter.run(&req, &mut run)?;
+
                println!(
+
                    "Run CI run #{}: {}, {} -> {}",
+
                    counter,
+
                    rid,
+
                    oid,
+
                    run.result().unwrap()
+
                );
            } else {
-
                return Err(BrokerError::NoAdapter(rid));
+
                eprintln!("ERROR: no adapter available for repository {rid}: not running CI");
            }
-

-
            println!(
-
                "Run CI run #{}: {}, {} -> {}",
-
                counter,
-
                rid,
-
                oid,
-
                run.result().unwrap()
-
            );
        }
    }
}