Urgent.News

What's breaking now, across thousands of outlets.

Tech

robots.txt Is a Contract: Parsing It Without Lying to Yourself

You fetched /robots.txt , got a 200, grepped for Disallow , found nothing scary, and started crawling. That is not reading the contract — that is skimming the cover page. Three things robots.txt does that naive parsers miss: 1. crawl-delay is not decoration. Many CMS-driven sites pair Disallow: /wp-admin/ with Crawl-delay: 10 . The delay is the site asking, in writing, for a polite rate. Ignoring…

Robots.txt is a contract that requires careful parsing to avoid misleading oneself. While fetching the file and checking for Disallow rules may seem sufficient, it falls short of comprehensively understanding the agreement. Three crucial aspects of robots.txt often overlooked by naive parsers are crawl-delay, user-agent scoping, and the contract's focus on the front door rather than hidden rooms.

Firstly, crawl-delay is not merely a decorative element. CMS-driven sites may specify a delay in robots.txt, asking for a polite rate of crawling. Ignoring this delay due to its absence in RFCs quoted by scrapers can transform a permitted crawl into a self-inflicted cascade of 429 errors. Treat crawl-delay as a hard floor on per-host interval, akin to the Disallow rules.

Secondly, user-agent scoping is a trap for those who rely on copy-paste configurations. A robots.txt file can include a wildcard block for all user-agents, but if your UA string is a default library token, this block applies to you. Parse the file per user-agent group, identify your specific group, and disregard the rest. Most quick parsers that concatenate rules globally will inaccurately report that only certain pages are blocked.

Lastly, the robots.txt file serves as an advertisement rather than an inventory of accessible resources. Omitted from the file are often the interesting data, such as API endpoints, staging hosts, and print-variant pages. The contract governs the front door, while the side rooms are governed by the Terms of Service, not the robots.txt file.

When conducting a crawl, follow this practical checklist: parse per user-agent group, resolve the matching group for your exact UA token (case-insensitive, last-match-wins), honor crawl-delay (or set your own floor of 2 seconds with jitter), treat Sitemap: lines as hints, verify freshness by sampling rather than trusting the lastmod value, and log the robots.txt hash with each crawl run.

This practice will reveal when the contract changes mid-run, allowing your pipeline to re-evaluate instead of crawling the updated site under outdated assumptions. A contract reviewed only once at the start is insufficient; re-check it, respect it, and log that you did.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in Tech

The Red Pencil Workshop

The workshop opens on a staged failure, because a visible row count teaches faster than a definition. On the projector, a fake ledger shows three captures for one invoice after a short reply suggested…

  • Red Pencil Workshop uses staged failure to teach concepts
  • Workshop employs red pencil as script exit line
  • Focus on stopping at one process to deepen understanding

Thinking about the conditions for closing a customer inquiry in code: Sending and completion are different

고객 문의를 시스템에서 ‘완료’로 옮기는 시점은 단순히 답장을 보냈을 때가 아닙니다. 요청을 실제로 처리했더라도 고객에게 확인 대상과 재문의 경로를 알리지 않았다면, 상태는 닫혔지만 대화는 닫히지 않은 셈입니다. 이 글은 작은 팀에서 문의 상태를 설계할 때 쓸 수 있는 종료 조건 을 정리합니다. 특정 제품 구현이 아니라 운영 규칙의 예시입니다.

  • Closing a customer inquiry requires more than just sending an email.
  • Completion state occurs when agreed standards are satisfied and recorded.
  • Customer confirmation is necessary before marking an inquiry as completed.

10 Curated PMP Mistakes That Drop Paid Filters and Kill Fill

On October 6, 2026 , the IAB Tech Lab opened a public comment period aimed at simplifying programmatic plumbing. Curated private marketplace lines are a big part of that conversation: buyers pay for…

  • Curated private marketplace lines play significant role in programmatic plumbing streamlining.
  • Upstream filter becomes non-existent when operations treat structure as generic PMP row.
  • Leaving privateauction unset allows open auction competition on invite-only packages.

More from Tuesday 13 October →