diff --git a/scripts/profile_sync.py b/scripts/profile_sync.py index 405228d35..4a4bcf376 100644 --- a/scripts/profile_sync.py +++ b/scripts/profile_sync.py @@ -1591,7 +1591,11 @@ def build_report( try: views = select_views(profile, cache_dir, offline) - except upstream.GoneError: + except upstream.RateLimitError: + raise + except upstream.UpstreamError: + # citron's dead domain now resolves to an unrelated host that fails + # TLS: for a forge the profile declares gone, any refusal agrees. if stated_gone: # The profile says the forge is gone and the forge agrees. That is # a recorded fact, not an open problem: the refs describe the last diff --git a/tests/test_profile_sync.py b/tests/test_profile_sync.py index 61f51538b..00ddc8c05 100644 --- a/tests/test_profile_sync.py +++ b/tests/test_profile_sync.py @@ -1840,6 +1840,15 @@ class TestDeclaredDeadUpstream(TestBuildReport): self.assertIn("withdrawn, HTTP 451", report.skipped) self.assertEqual(report.needs_review(), 0) + def test_any_refusal_of_a_declared_dead_forge_agrees(self): + # citron's taken domain now resolves and fails TLS. + def tls(*a, **k): + raise profile_sync.upstream.UpstreamError("TLSV1_UNRECOGNIZED_NAME") + + profile_sync.upstream.resolve_head = tls + report = build_report("test", self._profile_with("domain taken"), self.dir) + self.assertIn("declared", report.skipped) + def test_a_declaration_the_forge_contradicts_is_reported(self): """The forge answered: the declaration has outlived its truth.""" self.files[("pinsha", "a.c")] = ["hit"]