From 38969bbfadf2854f6acb1e515f8f388a01a018c2 Mon Sep 17 00:00:00 2001 From: DanConwayDev Date: Fri, 9 May 2025 20:00:24 +0100 Subject: fix: always try git servers over other protocols remove the code that guessed whether it was an authentication failure and gave up is it wasn't. this prevents it from trying http for push when ssh is not supported eg. ngit-relay --- src/bin/git_remote_nostr/list.rs | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) (limited to 'src/bin/git_remote_nostr/list.rs') diff --git a/src/bin/git_remote_nostr/list.rs b/src/bin/git_remote_nostr/list.rs index eba573b..2d233ae 100644 --- a/src/bin/git_remote_nostr/list.rs +++ b/src/bin/git_remote_nostr/list.rs @@ -22,9 +22,8 @@ use crate::{ fetch::{fetch_from_git_server, make_commits_for_proposal}, git::Repo, utils::{ - Direction, fetch_or_list_error_is_not_authentication_failure, get_open_or_draft_proposals, - get_read_protocols_to_try, get_short_git_server_name, join_with_and, - set_protocol_preference, + Direction, get_open_or_draft_proposals, get_read_protocols_to_try, + get_short_git_server_name, join_with_and, set_protocol_preference, }, }; @@ -244,12 +243,6 @@ pub fn list_from_remote( format!("list: {formatted_url} failed over {protocol}: {error}").as_str(), )?; failed_protocols.push(protocol); - if protocol == &ServerProtocol::Ssh - && fetch_or_list_error_is_not_authentication_failure(&error) - { - // authenticated by failed to complete request - break; - } } } } -- cgit v1.2.3