Fail closed when TES NSFW, takedown, nullcast, or media reads error - #134
Open
Pitchfork-and-Torch wants to merge 1 commit into
Conversation
Interstitial on a quote/RT/ancestor is keep-and-warn, not Drop. The leak next to that is TES nsfw/takedown/nullcast/media RPC failure treated as "flag unset", so those rules never fire and the post serves clean. Co-authored-by: Jon Bailey <Pitchfork-and-Torch@users.noreply.github.com>
This was referenced Sep 7, 2026
This was referenced Sep 7, 2026
Closed
Closed
Closed
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Wave 2 check
Quote / RT / ancestor
Action::Interstitialdoes not setdrop_ancillary_posts. Verified.should_drop_reasononly matchesAction::Drop.AncillaryVFFilterreads that flag. Home NSFW rules emit Interstitial; Recs has Drop twins (NSFW_HIGH_PRECISION_DROP, etc.). Interstitial means keep-and-warn, not hard-drop. Not rewritten.This is not #115 (Following quotes at Home), #117 (QuoteHydrator TES), #118 (quoted id on RTs), #119 (RT primary looked up by wrapper id), or #121 (VF
Err/ missing key). #121 leftover text called this Interstitial≠Drop path out and said TES-flag miss is separate.Bug
TES tweet-flag RPCs (
nsfw_user,nsfw_admin,takedown_reasons,nullcast,media) already distinguish Found / NotFound / Failed.build_tweet_featuresthen doesget(...).unwrap_or(false)andget_or_default.Failed and NotFound both become “flag unset”. NSFW interstitial / Recs Drop, legal takedown, nullcast, and DMCA/geo rules never see the label.
TesHydrator::hydrate_tweets→TweetHydrationNsfwAuthorInterstitialRule, tweet NSFW Recs drops, legal takedown,NullcastedTweetDropRule, Recs DMCA/geoGenuine
NotFound/Ok(None)(no flag) is unchanged.Fix
If any of those five lookups is Failed for a tweet id, drop that candidate from the hydrated set.
FilterTweetsalready maps a missing hydrated candidate toVerdict::unresolved_author(Drop /UnspecifiedReason). MixerVFFilterandshould_drop_ancillaryalready drop that reason.Do not treat Interstitial as Drop.
Tests
retain_candidates_with_usable_tes_flagsdrops only the Failed idHydrated::is_failedis true only for FailedStandalone decision-table harness (same Found / NotFound / Failed arms): 12 assertions passed.
cargo testcannot run. Public dump has no visibility-filtering / Home Mixer manifest.Leftover
Gizmoduck author NSFW miss is #125. Socialgraph relationship miss still fail-opens as “not muted / not blocked”.