tonhowtf/omniget · error · anyhow::Error

Post not available; graphql=

Error message

Post not available; graphql='{}'; syndication_extract='{}'; html='{}'

What it means

native_get_media_info tries three strategies in order: GraphQL API, syndication JSON extraction, and HTML scraping (request_html_media). This error is raised only when all three fail, combining each strategy's error message into a single string. It typically means the post is unavailable (deleted, private, age-restricted) or Twitter is blocking all guest access paths.

Solutions

  1. Check whether the tweet is deleted, protected, or age-restricted in a browser — this error frequently means the post genuinely is not accessible anonymously.
  2. Inspect each embedded error (graphql / syndication_extract / html) for rate limiting (429) and retry after backoff if so.
  3. Update yt-dlp and fall back to it when all native strategies fail.
  4. Add authenticated cookie/token support for age-restricted or login-walled content.
  5. Update the HTML scraper selectors if html='...' shows a parse/selector failure after an X UI change.

Example fix

// before
return Err(anyhow!("Post not available; graphql='{}'; syndication_extract='{}'; html='{}'", graphql_err, syndication_extract_err, html_err));
// after
if [graphql_err.to_string(), syndication_extract_err.to_string(), html_err.to_string()]
    .iter().any(|e| e.contains("429")) {
    return Err(anyhow!("Post temporarily unavailable (rate limited); retry with backoff"));
}
return Err(anyhow!("Post not available; graphql='{graphql_err}'; syndication_extract='{syndication_extract_err}'; html='{html_err}'"));
Defensive patterns

Strategy: retry

Validate before calling

// check availability early and detect retryable upstream failures
async fn tweet_reachable(url: &str) -> bool {
    // HEAD/GET the syndication endpoint; false likely means deleted/private/restricted
    reqwest::Client::new().head(syndication_url_for(url)).send().await
        .map(|r| r.status().is_success()).unwrap_or(false)
}

Try / catch

match native_get_media_info(url).await {
    Ok(info) => download(info),
    Err(e) => {
        let m = e.to_string();
        if m.contains("429") { retry_with_backoff(3); }
        else if m.contains("Post not available") { notify_user_post_unavailable(); /* offer yt-dlp fallback */ }
        else { return Err(e); }
    }
}

Prevention

When it happens

Trigger: GraphQL call fails (auth/rate-limit/429 or missing tweet), syndication extraction fails (error/empty payload), and HTML scrape fails (login wall, changed markup) — all within one native_get_media_info call on the same tweet URL.

Common situations: Deleted or protected tweets, age-restricted content requiring an X login, Twitter hardening guest access so GraphQL/syndication return errors simultaneously, regional blocks, and markup changes breaking the HTML scraper during X UI updates.

Related errors


AI-assisted analysis of tonhowtf/omniget@8600b91f42 (2026-09-12). Data as JSON: /api/errors/2e85c1760b2fbf01. Report an issue: GitHub.

Appendix: source

Thrown at src-tauri/src/platforms/twitter/mod.rs:996

            Err(graphql_err) => {
                tracing::warn!(
                    "[twitter] graphql lookup failed for tweet_id={}: {}",
                    tweet_id,
                    graphql_err
                );
                match self.request_syndication(&tweet_id).await {
                    Ok(syndication) => match Self::extract_syndication_media(&syndication) {
                        Ok(items) => items,
                        Err(syndication_extract_err) => {
                            tracing::warn!(
                                "[twitter] syndication media extraction failed for tweet_id={}: {}",
                                tweet_id,
                                syndication_extract_err
                            );
                            match self.request_html_media(url).await {
                                Ok(items) => items,
                                Err(html_err) => {
                                    return Err(anyhow!(
                                        "Post not available; graphql='{}'; syndication_extract='{}'; html='{}'",
                                        graphql_err,
                                        syndication_extract_err,
                                        html_err
                                    ));
                                }
                            }
                        }
                    },
                    Err(syndication_err) => {
                        tracing::warn!(
                            "[twitter] syndication lookup failed for tweet_id={}: {}",
                            tweet_id,
                            syndication_err
                        );
                        match self.request_html_media(url).await {
                            Ok(items) => items,
                            Err(html_err) => {

View on GitHub (pinned to 8600b91f42)