tonhowtf/omniget · error · anyhow::Error
nenhum link do TikTok na entrada (cole as URLs, escolha um…
Error message
nenhum link do TikTok na entrada (cole as URLs, escolha um .txt ou informe um perfil)
What it means
run() in tiktok/download.rs validates the resolved download queue before proceeding; when the queue is empty after parsing all input sources (pasted URLs, a .txt file, or a profile), it aborts with this anyhow error. It exists to fail fast with a clear message instead of silently downloading nothing. It is a guard against every input source yielding zero TikTok links.
Solutions
- Verify the input actually contains valid tiktok.com URLs (https://www.tiktok.com/@user/video/...) and fix the input string or file.
- If using a .txt file, confirm it is non-empty, UTF-8, and has one URL per line with no comment-only content.
- If relying on a profile source, check the profile exists and has public videos; try pasting direct video URLs instead.
- Check that opts.limit is not zeroing out the queue and that any pre-filters are not discarding every entry.
- Log the parsed queue length before run() to identify which input source failed to contribute links.
Example fix
// before
cli.run(Input::Text("check my tiktok".into()), opts).await?;
// after
let input = "https://www.tiktok.com/@user/video/7301234567890123456";
cli.run(Input::Text(input.into()), opts).await?; Defensive patterns
Strategy: validation
Validate before calling
// Rust
fn has_tiktok_urls(input: &str) -> bool {
input.lines().any(|l| l.contains("tiktok.com/") && l.contains("/video/"))
}
if !has_tiktok_urls(&raw_input) {
eprintln!("Nenhuma URL do TikTok encontrada na entrada");
return Ok(());
} Type guard
fn is_non_empty_queue(q: &[Entry]) -> bool { !q.is_empty() } Try / catch
match run(opts).await {
Ok(items) => process(items),
Err(e) if e.to_string().contains("nenhum link do TikTok") => eprintln!("Entrada sem links válidos"),
Err(e) => return Err(e),
} Prevention
- Validate that input text or .txt files contain at least one tiktok.com/video URL before invoking run().
- Trim and filter blank/comment lines when loading .txt inputs.
- Show a live count of parsed links in the UI before starting the download.
- Unit-test parse+queue construction with edge-case inputs (empty file, no-URL text).
When it happens
Trigger: Calling run() when: the input string contains no recognizable TikTok URLs, opts.limit > 0 truncated an initially non-empty queue to zero (limit=0 edge interaction aside, a pre-empty queue), the profile/txt expansion produced no items, or a filter (watermark/quality) combined with an empty initial queue leaves nothing to download.
Common situations: User pastes text that includes no tiktok.com links (typos in the URL, links from another platform), passes a .txt file that is empty or only has comments/blank lines, or points at a profile that has no downloadable videos, so queue construction returns empty before the limit/truncate step.
Understand the failure class
Background: "must not be empty", "cannot be empty" — required-field validation errors across open-source libraries — this error's family across 41 libraries.
Related errors
- escolha a pasta de destino
- não reconheci esse perfil ou coleção
- informe um appid, um link da loja ou marque a biblioteca…
- escolha ao menos uma imagem
- escolha pelo menos um arquivo
AI-assisted analysis of tonhowtf/omniget@8600b91f42 (2026-09-12).
Data as JSON: /api/errors/b42c0fdf2db9a235.
Report an issue: GitHub.
Appendix: source
Thrown at src-tauri/omniget-core/src/core/tools/tiktok/download.rs:179
report(
&progress,
ID,
"progress",
0,
None,
Some(format!("lendo {}", profile)),
);
for url in expand_profile(profile, opts.limit, cookies.as_deref()).await? {
if !queue.contains(&url) {
queue.push(url);
}
}
}
if opts.limit > 0 && queue.len() > opts.limit as usize {
queue.truncate(opts.limit as usize);
}
if queue.is_empty() {
return Err(anyhow!(
"nenhum link do TikTok na entrada (cole as URLs, escolha um .txt ou informe um perfil)"
));
}
let selector = format_selector(opts.watermark, &opts.quality);
let ffmpeg = crate::core::dependencies::find_tool("ffmpeg").await;
let pacer = Pacer::new(opts.delay_ms);
let total = queue.len() as u64;
let mut items: Vec<ItemResult> = Vec::with_capacity(queue.len());
for (i, url) in queue.iter().enumerate() {
let target = parse_target(url);
let (author, id) = match &target {
Some(Target::Video { user, id }) => (user.clone().unwrap_or_default(), id.clone()),
_ => (String::new(), String::new()),
};
report(
&progress,View on GitHub (pinned to 8600b91f42)