refactor(subs): remove podnapisi
ci / web (push) Successful in 30s
ci / rust (push) Failing after 1m58s
e2e / e2e (push) Failing after 2m15s

This commit is contained in:
Miguel Palhas
2026-08-26 22:58:01 +01:00
parent 3f4c1ade3b
commit 4cec2b6ed5
26 changed files with 44 additions and 1405 deletions
+1 -5
View File
@@ -275,8 +275,6 @@ async fn probe_subtitles(state: &AppState) -> SubtitleHealth {
async fn probe_provider(state: &AppState, id: &str) -> ProviderCheck {
let check = match state.subtitle_provider(id) {
Some(provider) => check_from(provider.probe().await),
// Only reachable for a provider that needs credentials: Podnapisi is
// anonymous (#215) and is always attached, so it never lands here.
None => Check::unconfigured(format!(
"{id} is enabled but has no credentials — they are bootstrap config, not a setting"
)),
@@ -481,15 +479,13 @@ mod tests {
#[tokio::test]
async fn an_enabled_provider_without_credentials_is_unconfigured() {
let (_dir, state) = application().await;
// The seed row enables opensubtitles and podnapisi; none are attached.
// The seed row enables OpenSubtitles; none is attached.
let body = report(state).await;
assert_eq!(
body["subtitles"]["providers"],
serde_json::json!([
{ "id": "opensubtitles", "status": "unconfigured",
"detail": "opensubtitles is enabled but has no credentials — they are bootstrap config, not a setting" },
{ "id": "podnapisi", "status": "unconfigured",
"detail": "podnapisi is enabled but has no credentials — they are bootstrap config, not a setting" },
])
);
assert_eq!(body["status"], "degraded");
+2 -2
View File
@@ -400,7 +400,7 @@ mod tests {
fn valid_input() -> serde_json::Value {
serde_json::json!({
"wanted_languages": ["pt-PT", "en"],
"providers_enabled": ["opensubtitles", "podnapisi"],
"providers_enabled": ["opensubtitles"],
"translation_engine": null,
"provider_daily_budgets": { "opensubtitles": 100 },
"translator_daily_budgets": {},
@@ -423,7 +423,7 @@ mod tests {
);
assert_eq!(
settings["providers_enabled"],
serde_json::json!(["opensubtitles", "podnapisi"])
serde_json::json!(["opensubtitles"])
);
assert!(settings["translation_engine"].is_null());
// `available_engines` is a fact about the build, not about the seed
+1 -1
View File
@@ -2609,7 +2609,7 @@ mod tests {
async fn a_grab_naming_an_unconfigured_provider_is_a_422() {
let fixture = stub_application().await;
let mut body = pt();
body["provider"] = serde_json::json!("podnapisi");
body["provider"] = serde_json::json!("unconfigured");
let (status, _) = grab(&fixture, body).await;
assert_eq!(status, StatusCode::UNPROCESSABLE_ENTITY);
}