Skip to content

Releases

v1.11.1

Choose a tag to compare

@Goldziher Goldziher released this 16 Oct 07:26

Fixed

  • WebAssembly accepts gzip, deflate and Brotli responses already decompressed by Fetch while continuing to reject unsupported or partially decoded content encodings.
  • Worker requests retain their watched page's SSRF policy when Chrome delivers the request before the worker lifecycle event.

Zig

Add to your build.zig.zon:

.dependencies = .{
    .crawlberg-zig = .{
        .url = "https://github.com/xberg-io/crawlberg/releases/download/v1.11.1/crawlberg-zig-v1.11.1.tar.gz",
        .hash = "crawlberg-1.11.1-IoY1Ck8mZC-7WiStH_Qyk8UCfa9QhfmfG7ewiGMXZ45l",
    },
},

v1.11.0

Choose a tag to compare

@Goldziher Goldziher released this 15 Oct 20:56

[1.11.0] - 2026-10-15

Upgrading

  • The minimum supported Rust version is now 1.95, matching the updated sysinfo dependency.

  • YAML bypass configurations reject duplicate mapping keys and raw NUL characters.

  • Set cookies_enabled=true for cookie-based login through a browser endpoint or saved profile.
    false now suppresses automatic Cookie headers from those stores as well as redirect cookies.

  • The converter upgrade renders an image with an empty source as its alt text and keeps markup
    inside a textarea as literal text, instead of converting it into Markdown.
    Empty headings in headerless HTML fragments no longer prevent conversion of the remaining body.

  • Swift RustBridge wrappers for AuthConfig, CrawlEvent, HostMatcher and PageAction now
    return tagged JSON with their payloads from to_string(), including authentication credential
    fields. The facade toString() still returns the variant tag.

  • CrawlError gained TooManyRedirects. Exhaustive Rust error matches need the new case.
    Redirect exhaustion uses its own error family; the underlying network error remains its source. (#676)

  • SSRF exceptions now inherit the crawl-error family. Python's SsrfError base changes
    from Exception to CrawlError. The C# SsrfErrorException base changes from
    CrawlbergException to CrawlErrorException; Java changes from CrawlbergRsException to
    CrawlErrorException. Place specific SSRF handlers before handlers for the new parent.
    Existing catches of the older general base still work. (#676)

  • The generated Node Rust shim's SSRF_ERROR_ERROR_TOO_MANY_REDIRECTS_CODE changes from
    v1.10.3's 2 to 101; CRAWL_ERROR_ERROR_TOO_MANY_REDIRECTS_CODE is 100. These values
    describe the Rust shim; JavaScript errors retain NAPI's GenericFailure status and the
    error's display text. (#676)

  • crawlberg-browser: PageError gained UnfollowedRedirect. Native interaction uses
    it for unfinished HTTP redirects. A match on PageError with no wildcard arm needs an arm
    for the new variant. (#695)

  • A BypassProvider must say what the body of its answer is. BypassResponse has a new field,
    body_kind: BypassBody::Bytes when body_bytes holds the bytes the origin sent, and
    BypassBody::Text when body holds text that is decoded already, such as the HTML a vendor's
    browser rendered. A BypassResponse { .. } literal does not compile until it sets the field.

  • crawlberg-browser: NativeBrowserConfig and RenderedPage each have a new public field,
    document_decoder and charset, and the crate has a new public type, DocumentDecoder. A
    struct literal that names every field must add the new one; ..NativeBrowserConfig::default()
    needs no change.

  • CachedPage has two new public fields, charset and decoded. A CrawlCache that stores
    the entry as it gets it needs no change. A cache entry that an earlier release stored is not
    served: the page is fetched again and the entry is replaced. A CrawlCache that builds its own
    entries must set decoded to true for a body it stored as decoded text:
    ..CachedPage::default() sets it to false, and such an entry is not served.

  • BrowserConfig and BrowserPoolConfig each have a new public field, private_pipe. A
    Rust struct literal that names every field must add it; a literal with ..Default::default()
    needs no change. The language packages are not changed: their BrowserConfig has no new
    field and its constructors take the same arguments.

  • CrawlPageResult, LinkInfo, FrontierEntry and ContentConfig have new public fields.
    The first three have original_url. ContentConfig has strip_newlines, bullets,
    list_indent_width, strong_em_symbol, compact_tables, keep_inline_images_in and keep_hidden. A Rust
    struct literal that names every field must add them. ..Default::default() needs no change
    for CrawlPageResult, LinkInfo and ContentConfig; for FrontierEntry set
    original_url: None. The added fields are the last fields of CrawlPageResult, LinkInfo and
    ContentConfig. In Python, Dart, Zig and Swift, a v1.10.3 constructor call of these three
    types needs no change, and Java keeps the v1.10.3 constructor beside the full one; the entry
    for #717 under Fixed gives the form of the added fields in the bindings it names. A Go struct literal
    without keys must add the new fields. In the serialized JSON of these three types, the added
    keys are last: a consumer that compares JSON text with the output of an earlier build of the
    main branch sees a different key order, and the values are equal. A Frontier that stores
    its entries reads an entry of an earlier release with no change.

Added

  • ContentConfig.keep_hidden retains hidden elements and body templates in converted output.
    It defaults to false; scripts, styles, explicit exclusions and image settings keep their
    existing rules. The option applies to HTTP, browser and cached HTML. (#625)

  • Per-domain rate limiting emits TRACE events at crawlberg::rate_limiter with domain and
    numeric wait_ms fields for each selected pacing delay.

  • The vendored browser process Command::get_args() exposes a read-only iterator over the
    configured arguments. It does not change their order or launch behavior.
    (#702)

  • Frontier::pop_batch_excluding_hosts selects entries whose hosts are not waiting for a
    rate-limiter turn, without removing or reordering retained entries. Return Some(entries)
    to support this selection, or None to retain the existing bounded-window fallback. The
    built-in FIFO and LIFO frontiers support it. (#684)

  • BREAKING (swift, kotlin, dart): the error type has a new case, ConversionFailed. A caller
    that matches the error exhaustively with no default case must add a case for it. Rust callers
    are not affected. The error is for a page that was fetched but could not be converted to
    Markdown. Its text starts with conversion_failed:. Python, Go, Java, C#, Kotlin, Swift, Dart
    and Zig have it as its own error class or error value. Node, Ruby, Elixir, PHP and the C
    interface have no class for any error case: read the text there. In PHP the text starts with
    [ConversionFailed] , and the usual conversion_failed: text follows it. The API server
    reports it as CONVERSION_FAILED with status 500, and the MCP server returns it as a tool error.

  • browser.private_pipe starts Chrome on a private debugging pipe (Linux and macOS). The
    key is a bool and its default is false: a caller that sets nothing gets the Chrome of the
    release before, with a debugging port on 127.0.0.1. With true:

    • The Chrome that crawlberg starts listens on no TCP port. crawlberg speaks the DevTools
      protocol with it over the pipe, so no other local process can drive the browser of a crawl.
      The profile directory of that Chrome has no DevToolsActivePort file. (#624)
    • The Chrome ends when the last process that holds the pipe ends. The process that started
      the Chrome holds it: when no other process does, the Chrome ends when that process exits,
      is killed with SIGKILL or gets a SIGTERM that it does not handle. A process that the owner
      forked without exec holds a copy of the pipe, and the Chrome runs until that process ends
      too. A process that the owner started with exec does not hold the pipe. Without the key
      this change does nothing for the Chrome of a killed process. (#620)
    • Limit: the pipe is less reliable than the debugging port when the machine is loaded. On a
      host at a load of 18 to 45, with 22 browser tests in parallel, the firewall test file was
      green in 2 of 10 runs on the pipe against 8 of 10 on the debugging port. In 5 of the 10 pipe
      runs a scrape failed with failed to open page after relaunch: browser: failed to create page: oneshot canceled; in 0 of the 10 runs on the debugging port. The cause is not known.
    • On Windows the key changes nothing. A Chrome behind browser.endpoint belongs to the caller
      and is not changed. The native backend ignores the key, with a warning.
    • The Rust BrowserPoolConfig has the same key for the Chrome that a pool launches. A scrape
      or crawl on a shared pool uses the pool's key. CrawlConfig::adopt_operator_egress sets the
      key from the operator, and reject_untrusted_fields refuses /browser/private_pipe from
      an untrusted caller.
    • The key is in the Rust API and in a CrawlConfig that crawlberg reads as JSON. The
      language packages (Python, Node, PHP, Ruby, Go, Java, C#, Kotlin, Swift, Dart, Elixir, Zig,
      WebAssembly, C) do not have it yet: a new constructor argument breaks the callers of some
      of them, and the generator release that adds an argument without that break is not out.
      #620 and #624 are fixed only with the key on.
  • ContentConfig has six options for the form of the Markdown. strip_newlines writes a line
    break in the HTML source of a paragraph as a space. bullets sets the list markers for each
    level of nesting, and list_indent_width the spaces for each level. strong_em_symbol sets the
    emphasis marker. compact_tables writes table cells with no padding. keep_inline_images_in
    names the elements in which an image stays an image. Each default is the default of the
    converter, so a page converts as before. bullets accepts -, * and +,
    list_indent_width accepts 1 to 256, and strong_em_symbol accepts * or _. Another value
    is a configuration error. (#612)

  • CrawlPageResult.original_url and LinkInfo.original_url give the address as the link wrote
    it. The link is resolved against the base address of its page, with no other change: no
    percent-encoding, no change of a backslash, no removal of dot segments. For the start page it
    is the address that the caller passed. A redirect does not change it...

Read more

v1.10.3

Choose a tag to compare

@Goldziher Goldziher released this 09 Oct 00:21

Full Changelog: v1.10.0...v1.10.3

Zig

Add to your build.zig.zon:

.dependencies = .{
    .crawlberg-zig = .{
        .url = "https://github.com/xberg-io/crawlberg/releases/download/v1.10.3/crawlberg-zig-v1.10.3.tar.gz",
        .hash = "crawlberg-1.10.3-IoY1CqvWTyhN8YIKSXFOr_wcEdXHJGoYv8qIp3YiOibw",
    },
},

v1.10.2

Choose a tag to compare

@Goldziher Goldziher released this 06 Oct 20:34

Changed

  • Update html-to-markdown-rs to 3.17.2.

Zig

Add to your build.zig.zon:

.dependencies = .{
    .crawlberg-zig = .{
        .url = "https://github.com/xberg-io/crawlberg/releases/download/v1.10.2/crawlberg-zig-v1.10.2.tar.gz",
        .hash = "crawlberg-1.10.2-IoY1CorIUScOgiKHD-t5J9LOSkPlyv8-gfl_OAr7gaDq",
    },
},

v1.10.1

Choose a tag to compare

@Goldziher Goldziher released this 05 Oct 14:34

Full Changelog: v1.10.0...v1.10.1

Zig

Add to your build.zig.zon:

.dependencies = .{
    .crawlberg-zig = .{
        .url = "https://github.com/xberg-io/crawlberg/releases/download/v1.10.1/crawlberg-zig-v1.10.1.tar.gz",
        .hash = "crawlberg-1.10.1-IoY1CpA0TydHxZYmK-AhMdHEpea-1aE0FDdTtPHcG5Oy",
    },
},

v1.10.0

Choose a tag to compare

@Goldziher Goldziher released this 05 Oct 10:42
d6aed8e

What's Changed

  • chore(alef): repin to 0.93.0 and regenerate bindings by @Goldziher in #53
  • chore(alef): repin to 0.93.1 by @Goldziher in #54
  • perf(engine): share robots outcomes across crawls by @Goldziher in #52
  • fix(browser): stop double-dashing default Chrome flags by @tobocop2 in #69
  • ci(python): publish a macOS x86_64 wheel by @tobocop2 in #58
  • fix(browser): resolve a redirected page against the URL Chrome landed on by @tobocop2 in #85
  • fix(crawl): stop fetching once the stream receiver is dropped by @tobocop2 in #83
  • fix(http): retry only the status codes marked retryable, and report the real status by @tobocop2 in #84
  • fix(crawl): stop starting batch seeds once the stream is dropped by @tobocop2 in #129
  • fix(markdown): resolve relative links against the page URL by @tobocop2 in #82
  • test(crawl): run the subdomain tests without the system resolver by @tobocop2 in #106
  • fix(ci): stop the header gate failing on release lag, drop a flaky test by @Goldziher in #211
  • ci: keep every push to main from cancelling the previous run by @Goldziher in #392
  • fix(browser): resolve every subresource address with the URL parser by @tobocop2 in #263
  • fix(html): decode attribute values, match tags in any case, and resolve images against the base by @tobocop2 in #98
  • fix(html): match attribute values in any case, and resolve head links against the base by @tobocop2 in #122
  • fix(html): read attribute values and addresses as a browser does by @tobocop2 in #184
  • fix(html): compare URL schemes in any letter case by @tobocop2 in #213
  • fix(html): read refresh targets with the HTML refresh steps by @tobocop2 in #277
  • fix(html): follow the refresh a browser follows, and ignore javascript: targets by @tobocop2 in #298
  • test(bench): wait for samples instead of sleeping a fixed window by @tobocop2 in #432
  • test(rate-limit): stop the jitter assertion colliding 1% of runs by @Goldziher in #259
  • ci(e2e): ignore the C leg's staged FFI artefacts by @Goldziher in #253
  • perf(crawl): share the compiled include patterns across fetches by @Goldziher in #247
  • test(html): cover raw-text masking and feed discovery with a charset by @Goldziher in #251
  • fix(html): skip script addresses in image and asset discovery by @tobocop2 in #301
  • fix(html): skip script addresses in feed, icon, canonical and hreflang links by @tobocop2 in #307
  • fix(credentials): keep user credentials out of URLs and send them only to the seed host by @tobocop2 in #431
  • fix(crawl): read robots none and scope named directives by @Goldziher in #255
  • fix(browser): run a module script loaded from a source address in the native backend by @tobocop2 in #476
  • fix(html): a data or javascript base address falls back to the page address by @tobocop2 in #450
  • fix(html): a refresh delay with no digit is no refresh, as in Chrome by @tobocop2 in #453
  • test(assets,http): cover asset download and credential redaction by @Goldziher in #395
  • fix(redirect): resolve a meta refresh target against the page's base by @tobocop2 in #469
  • fix(redirect): a redirect to a non-web address is not followed by @tobocop2 in #470
  • fix(html): extract links after an abruptly closed comment by @tobocop2 in #466
  • fix(security): redact credentials from an address that does not parse by @tobocop2 in #257
  • fix(ssrf): stop printing an unrecognised scheme in the scheme refusal by @tobocop2 in #350
  • chore(alef): pin alef to the version main was generated with by @tobocop2 in #433
  • fix(security): redact secrets in bypass and config debug output (#111, #145, #149) by @tobocop2 in #491
  • fix(security): redact sensitive header values in debug output (#155) by @tobocop2 in #492
  • fix(robots): match robots rules against the user agent each request sent by @tobocop2 in #482
  • fix(html): read link tags at the boundaries the markdown sees by @tobocop2 in #488
  • fix(ssrf): check the IPv4 address inside the IPv6 embedding forms by @tobocop2 in #107
  • fix(browser): connect the native browser only to the address the SSRF check approved by @tobocop2 in #489
  • fix(security): redact sensitive header values on a document's Debug by @Goldziher in #216
  • fix(crawl): keep the seed's credential scope for every page of a sequential crawl by @tobocop2 in #495
  • fix(config): accept an upper-case ws:// or wss:// browser endpoint by @Goldziher in #397
  • fix(sitemap): land the sitemap stack and fetch cross-host sitemaps from their own hosts by @tobocop2 in #494
  • fix(http): give a custom retry policy the status of a failed attempt by @tobocop2 in #130
  • fix(wasm): rotate the user agent per page on the wasm crawl loop by @tobocop2 in #499
  • fix(map): resolve a redirected page's links against its final URL by @tobocop2 in #391
  • fix(api): accept an address with an upper-case scheme by @tobocop2 in #242
  • fix(waf): return CDN-fronted 2xx pages as content and retry 429/503 behind CDNs by @tobocop2 in #496
  • test(map): run forty concurrent map and batch calls under a deadline by @tobocop2 in #497
  • fix(ssrf): deny the reserved 240.0.0.0/4 range by @tobocop2 in #185
  • fix(error): a 404 error prints its not_found prefix twice by @Goldziher in #396
  • fix(html): read raw text, link tags and the base from one html5ever pass by @tobocop2 in #501
  • feat(browser): let a caller choose the Chrome binary and add Chrome flags by @tobocop2 in #194
  • fix(http): carry the response status on a 403 and a WAF block by @Goldziher in #229
  • fix(map): follow a meta refresh or a Refresh header the way the crawl does by @tobocop2 in #505
  • fix(robots): read a robots.txt that says "blocked" in a comment as rules by @tobocop2 in #514
  • fix(sitemap): read a sitemap that lists a URL saying "blocked" behind Cloudflare by @tobocop2 in #520
  • fix(browser): remove each Chrome profile directory when its owner drops by @tobocop2 in #462
  • fix(browser): remove a browser profile method whose only flag is now refused by @tobocop2 in #304
  • fix(sitemap): read a gzip sitemap whatever its content type says by @tobocop2 in #535
  • test(http): give each client cache test a cache of its own by @tobocop2 in #537
  • feat(crawl): let URL filters match the full URL, and compile look-around by @tobocop2 in #181
  • fix(robots): skip a byte-order mark at the start of a robots.txt by @tobocop2 in #539
  • fix(engine): report a WAF block's real status with soft_http_errors by @tobocop2 in #544
  • ci: build the test targets under each feature by @tobocop2 in #546
  • fix(robots): read robots.txt with one parser in the engine and the browser by @tobocop2 in #548
  • fix(engine): give a custom refusal the soft_http_errors page by @tobocop2 in #557
  • fix(map): honour robots.txt and path filters for every page map fetches by @tobocop2 in #545
  • fix(e2e): expect no description from the unclosed-title fixture by @Goldziher in #250
  • docs(changelog): list two bug fixes under Fixed by @...
Read more

v1.9.0

Choose a tag to compare

@tobocop2 tobocop2 released this 03 Oct 19:15

Upgrading

  • In browser mode, max_redirects now counts the navigations a page starts. A meta refresh
    or a script navigation counts as one redirect, and past the limit the page stays where it is.
    A crawl with a low max_redirects that relied on a page's script to move it to the real page,
    such as a challenge page, needs a higher limit. In crawlberg-browser, NativeBrowserConfig
    gains max_redirects and RenderedPage gains redirects, so a struct literal of either needs
    the new field; NativeBrowserConfig::default() sets no limit. (#117, #193, #115)

  • The bypass provider holds its secrets in a type that never prints. In crawlberg-bypass,
    the auth scheme's token, user name and header or query value, and each fixed query value, are
    now a Secret. Its Debug and Display print ***, so a struct that derives Debug over it
    cannot show the key. Build one with .into() from a string, and read it with expose(). (#386)

  • The config check refuses a proxy password that is not percent-encoded. A #, / or ?
    in a proxy user name or password ends the address early, so http://user:4242#rest@proxy:8080
    was read as the host user on port 4242. Such an address now fails CrawlConfig::validate,
    and the error asks to percent-encode the credential or to set it in username and password.
    The error never shows the address. An address with no credentials and an @ in its path,
    query or fragment is refused too, and its error says that a proxy address takes no path,
    query or fragment.

  • The config check refuses proxy credentials set in two places. A proxy URL that holds a user
    name or password, together with username or password, now fails CrawlConfig::validate.
    Set the credentials in the URL or in the two fields, not both.

  • A proxy with only username set now sends its credentials. The HTTP client sends
    Proxy-Authorization with the user name and an empty password. Before, it sent credentials
    only when both username and password were set.

  • A proxy that a ProxyProvider returns gets the same check as the configured proxy. A
    provider proxy that the check refuses is not used: the request goes direct, and an ERROR line
    names the target host and the reason, never the proxy URL. Its credentials reach the proxy as
    Proxy-Authorization. The provider is asked once for each request, redirect hops included,
    so a rotating provider no longer sends one proxy's credentials to another, and a refused proxy
    logs one ERROR line for each request. Each provider proxy has its own connection pool.

  • A native browser render goes through the proxy that a ProxyProvider picks. Before, a
    render ignored the provider and connected directly. Now the render asks the provider once for
    the page's host, and the page load and every request the page makes go through that proxy with
    its credentials. If the provider returns no proxy, the render goes direct, as an HTTP fetch
    does. browser.proxy, if set, still wins over the provider for renders. (#248)

  • A Chrome render with a ProxyProvider fails instead of going direct. The Chrome backend
    cannot render through a provider, so a Chrome render with a provider and no browser.proxy
    now fails with an error that names the fix: use the native backend, or set browser.proxy.
    HTTP fetches with the provider are not affected. (#248)

  • crawlberg-browser: the native backend takes a proxy with its credentials apart.
    NativeBrowserConfig gains proxy, an UpstreamProxy: an address that holds no user name or
    password, and optional ProxyCredentials. UpstreamProxy::new refuses an address that holds
    credentials, and an address with an @ after the host, which an unencoded #, / or ? in a
    password leaves behind. Its error never shows the address. The same type replaces the proxy URL
    string in the browser context, the HTTP clients, the module loader and the JS runtime
    constructors.

  • crawlberg-browser: NativeBrowserConfig.proxy_url is deprecated. Set proxy instead.
    proxy_url still works, and a user name and password in the URL become the proxy
    credentials. It gets the same checks as proxy, so an unencoded #, / or ? in a password,
    which leaves an @ after the host, fails the render. A path, a query or a fragment with no @
    is accepted, as in v1.8.0. An unusable
    proxy_url fails the render even when proxy is set. When both are set, they must name the
    same proxy: a different address or other credentials fail the render with an error that names
    both fields.

  • The config check refuses a SOCKS proxy where no client can use it. A socks5:// or
    socks5h:// address in proxy now fails CrawlConfig::validate with "SOCKS proxies are not
    supported". Crawlberg's HTTP clients are built without SOCKS support, so every HTTP fetch
    through such a proxy failed at connect time. The same holds for browser.proxy with the native
    backend. Chrome speaks SOCKS, so with the Chrome backend browser.proxy still takes socks4://
    and socks5://. Chrome has no socks5h scheme. Use an http or https proxy everywhere else.

  • With the Chrome backend, the config check refuses a crawl-wide proxy with credentials. A
    Chrome render uses proxy when browser.proxy is not set, and Chrome cannot use a proxy with a
    username or password. Such a config now fails CrawlConfig::validate instead of every browser
    render. The HTTP client still takes the proxy. To keep it, set browser.proxy to a proxy that
    needs no credentials, use the native backend, or set browser.mode to never. A build without
    the Chrome backend is not affected.

  • The config check also checks browser.proxy. A browser.proxy with a scheme the browser
    cannot use, such as gopher://, now fails the config check instead of the render. (#249)

  • In browser mode, a page with an error status is now the error HTTP mode returns. A scrape
    of such a page returned the rendered HTML with status 200. It now returns the same error that
    HTTP mode returns for the same status. The statuses are 401, 403, 404, 408, 410, 429, 500, 502,
    503 and 504. A 403, 429 or 503 page is a WAF error when its headers or its body name a WAF,
    as in HTTP mode, so it escalates instead of being retried. A page with another status, such as
    501, 505 or 599, stays a page, as in HTTP mode. Code that expects a page from every browser-mode
    scrape must handle these errors. A crawl in browser mode now keeps the same pages as one in HTTP
    mode. Under soft_http_errors a 404 or 403 page, and a 404 at the end of a redirect, is a page
    that keeps its status and has an empty body, as in HTTP mode. The Chromiumoxide backend reports the status and the
    response headers of the document the page shows, so a WAF block is found from the headers of a
    403, 429 or 503 page as well as from its body. When Chrome shows its own error page in place of
    such a response, such as for a download or an empty body, only the headers are checked, because
    Chrome never rendered the body. (#143)

  • The native browser backend reports an empty body for a 204, 205 or 304. It reported an
    empty HTML skeleton for these statuses. It now reports an empty body, as HTTP mode does. If
    your code reads the body of such a page, expect an empty string. (#121)

  • interact now follows at most max_redirects redirects. The default is 10. The
    Chromiumoxide backend followed every redirect a chain offered, and the native backend followed
    up to 20. For a longer chain, interact returns the URL of the redirect at the limit. On the
    Chromiumoxide backend it also returns empty HTML and a failed result for each action. If an
    interact call must follow a longer chain, raise max_redirects. (#116, #115)

  • A Chromiumoxide browser fetch or interact session fails when Chrome reports no main
    frame.
    The redirect limit counts only the redirects of the page's main frame, so crawlberg
    must know that frame. If Chrome reports no main frame, or the read of it fails, the call
    returns a browser error that says the redirect limit cannot be applied. (#90)

  • ScrapeResult, CrawlPageResult and InteractionResult gained ssrf_refused_urls. The
    field is left out when it is empty, so an older crawlberg still reads a result with no refused
    request. A scrape or page result that lists one is rejected by an older reader, because both
    types refuse unknown fields.

  • BrowserConfig gained two fields and rejects unknown ones. chrome_path and chrome_args
    are always serialised, and BrowserConfig rejects unknown fields, so a browser configuration
    serialised by this version is rejected by every older crawlberg
    , even when both are unset.
    The break is one-directional: an older configuration still loads here, because both fields
    have defaults. (#79, #80)

  • BrowserPoolConfig.chrome_args now refuses entries that the pool used to launch with. The
    pool applies the rules of BrowserConfig.chrome_args, so these entries now fail: an entry
    without a leading -- (disable-gpu), a flag name with an uppercase letter, a flag named twice
    (--enable-features given two times), and --headless, --remote-debugging-port or
    --user-data-dir in any form, --headless=new included. BrowserPool::new still accepts the
    config: the refusal comes when the pool launches Chrome, as an error from warm and
    acquire_page that names BrowserPoolConfig.chrome_args. Write each flag once, as --flag or
    --flag=value with a lowercase name, and join several --enable-features values with commas.
    (#79, #80)

  • BrowserProfile::chrome_args() is deprecated. It returns a single --user-data-dir=<path>
    flag, and chrome_args now refuses --user-data-dir in any form, so the flag only helps a
    caller that starts Chrome itself. Nothing in crawlberg calls it: a profile reaches C...

Read more

v1.8.0

Choose a tag to compare

@Goldziher Goldziher released this 27 Sep 09:44

Includes twelve issues raised by an external evaluation, ten of them in the crawl path. Most were
defects a green e2e suite could not see: the fixtures covering the affected behaviours passed with
the bugs fully present, and the assertion vocabulary cannot express request counts or elapsed time
at all, so the whole "how many requests did we send, and how long did we wait" class was invisible
by construction.

Upgrading

  • CrawlPageResult gained two fields and rejects unknown ones. noindex_detected and
    nofollow_detected are always serialised, and CrawlPageResult carries
    #[serde(deny_unknown_fields)], so a page result serialised by this version is rejected by
    every older crawlberg
    — even when both values are false. The break is one-directional: an
    older result still loads here, because both fields default to false.

    What this affects:

    • A cross-version pipeline that serialises a crawl result on one crawlberg and reads it on
      another. Upgrade the readers before, or with, the writers.
    • A persisted CrawlCache: entries written by this version cannot be read back by an older
      build, so a rollback must treat the cache as cold rather than reuse it.
    • Any binding that round-trips a page result through JSON across the FFI boundary
      (cberg_crawl_page_result_from_json), where the core and the binding can be at different
      versions.
  • The regenerated bindings add two required CrawlPageResult constructor arguments. Code that
    constructs a CrawlPageResult by hand — Swift's init, Dart's const CrawlPageResult({...}),
    Ruby's initialize, the Java constructor, the Python signature — must pass noindex_detected
    and nofollow_detected. Reading a result that crawlberg returned is unaffected.

Four changes can affect an existing setup:

  • interact() now enforces the SSRF policy. It previously enforced none on the default browser
    backend, so a target ssrf.deny_private should have rejected was fetched anyway. Code that
    relied on reaching a loopback or private address through interact() must now opt in
    deliberately, the same way scrape() and crawl() already required. (#74)

  • Saved browser profiles. Default Chrome flags now actually reach Chrome (see below), so
    cookies in a browser_profile written by 1.7.2 or earlier may no longer be readable: they were
    encrypted with a keychain-backed key and the mock keychain uses a different one.

  • BrowserConfig gained two fields and rejects unknown ones. A configuration serialised by
    1.8.0 that carries overall_timeout or shutdown_timeout is rejected by older crawlberg
    versions. Older configurations still load unchanged.

  • CrawlPageResult.normalized_url now normalises the post-redirect URL rather than the
    originally discovered one, so it keys on where the content actually came from. This also feeds
    CrawlResult::unique_normalized_urls().

Added

  • CrawlEngineBuilder::document_filter lets a Rust consumer decide document materialization from
    the response bytes rather than the declared MIME type alone. The predicate receives the
    normalized MIME type, at most document_max_size bytes of the already bounded body, and the
    decision document_mime_types/the built-in classification would have reached, so it can widen
    that decision (by_declared_mime || bytes.starts_with(b"%PDF")) instead of replacing it.
    crawl(), scrape() and the wasm crawl loop all honour it. With no predicate the declared-MIME
    decision is unchanged.

    The predicate runs for every fetched response, an ordinary HTML page included, so one that
    returns true for HTML materializes every page as a DownloadedDocument — duplicating its whole
    body into the result and writing it to document_output_dir on native targets. Keep it as narrow
    as the documents it is meant to admit. (#95)

  • Relative links in page markdown pointed nowhere. The markdown kept each address exactly
    as the HTML wrote it, so rel/child.html could not be followed outside the page, and a
    <base href> had no effect. Relative addresses now resolve against the page's <base href>
    or the URL that served the page, the same base the links list uses. This covers <a href>;
    <img> src, data-src, data-lazy-src, data-original, data-srcset and srcset;
    src on <iframe>, <video>, <audio> and <source>; <blockquote cite>; and the
    addresses of <graphic>. Character references in an address are decoded first, so
    &#x2F;app resolves to /app. Absolute URLs, fragment-only links and mailto:,
    javascript: and data: addresses stay as written. Because resolved links are longer,
    fit_content can now drop a line of relative links that it kept before, the same way it
    already treated absolute links. (#63)

  • The markdown front matter showed the base address as written. A page with
    <base href="/other/"> got base: /other/. The front matter now shows the resolved base,
    the same address that relative links resolve against. (#94)

  • ContentConfig.extract_metadata leaves the YAML frontmatter out of a page's markdown when set
    to false. The head values remain available on PageMetadata, which is populated independently
    of the converter. (#64)

  • CrawlConfig.path_patterns_match_query matches include_paths/exclude_paths against the path
    and query (/blog?p=42) instead of the path alone. Path-only stays the default, because a
    pattern anchored with $ changes meaning once the query joins the text. (#61)

  • CrawlConfig.dedup_include_query keeps the query in the dedup key, with its parameters sorted,
    so /item?id=1 and /item?id=2 are no longer one page. strip_tracking_params and
    tracking_params remove tracking parameters from the URL that is fetched and reported, not only
    from the key. (#65)

  • CrawlConfig.retry_initial_delay_ms, retry_max_delay_ms and rate_limit_jitter_ratio make the
    first retry delay, the backoff ceiling and the per-domain delay jitter configurable. (#67)

  • BrowserConfig.overall_timeout and shutdown_timeout bound a browser fetch end to end. (#66)

  • CrawlPageResult.final_url and redirect_count report where a page's content came from and how
    many hops it took. (#62)

  • The Python release now publishes a macOS x86_64 wheel, so an Intel Mac no longer falls back to
    building the sdist. It carries a deployment target of 11.0, matching the existing arm64 wheel.
    (#57)

Fixed

  • The vendored C header gate failed for lag rather than for a defect. It required each
    prebuilt platform bundle's crawlberg.h to declare exactly the same C API as the canonical
    header, but a vendored copy ships beside a dylib from the last release, so it legitimately
    lacks whatever the canonical header has gained since — adding two CrawlPageResult getters
    for #135 turned main red for that reason alone. The comparison is now one-directional: a
    declaration the vendored copy has and the canonical header does not still fails, because that
    means a prebuilt bundle promising a symbol HEAD removed or re-signed, while declarations the
    copy is merely missing are reported as lag. (#162)

  • A whitespace-only favicon href or image src reported the page as its own favicon or image.
    The guard was is_empty(), which is false for " ", and resolving a whitespace-only reference
    against a base yields the base itself, so <link rel="icon" href=" ">, <img src=" "> and a
    blank og:image/twitter:image content all listed the page URL. Such an address is now
    skipped, via a shared is_blank_address helper. Only ASCII whitespace counts as blank, because
    HTML strips nothing else from a URL attribute — an NBSP-only reference is a real value and is
    percent-encoded (#191). Canonical (#137) and hreflang (#126) leak the raw value instead, because
    they do not resolve at all. (#220)

  • A browser fetch reported no response headers at all on the crawl path.
    browser_http_to_crawl built an empty header map, so every header a browser backend had
    collected was discarded before the crawl or the escalation path could read it — ETag,
    Cache-Control and X-Robots-Tag reached no caller and no WAF classifier, however faithfully the
    backend reported them. This is why a nofollow sent only as an X-Robots-Tag header had no effect
    in browser mode even after the crawl learned to honour it. Headers are now carried through. The
    chromiumoxide backend still hardcodes its own status, content type and headers, so this reaches
    callers today on the native backend only; #166 covers the rest. (#148)

  • Dropping a one-shot browser fetch ran no teardown at all. Teardown was straight-line code
    after the fetch, reached only once the fetch had finished, so a caller that dropped the future
    while it ran — a cancelled request, a select! that lost, a deadline above crawlberg — got none
    of it. Against a browser.endpoint Chrome that left crawlberg's CDP websocket open, and the tab
    it had opened open with it: a connected chromiumoxide::Browser owns no child process, so
    dropping it does nothing, and its handler loop never ends by itself. Against a launched Chrome
    the process went with the dropped handle, but its --user-data-dir stayed on disk. Teardown now
    belongs to a value whose Drop runs it, so a dropped fetch and a finished one take the same
    path, and the profile directory is owned by a guard from the moment it is created rather than
    from the moment the launch succeeds — a fetch cancelled mid-launch never had a session to tear
    down. One window remains open: the Chrome process that Browser::launch is still building
    cannot be reaped from outside it, so a fetch cancelled during the launch can leave that process
    behind, and it recreates the directory it was just removed from (#198). (#131)

  • Teardown waited five seconds for the CDP handler after killing a hung Chrome. Killing the...

Read more

v1.7.2

Choose a tag to compare

@Goldziher Goldziher released this 24 Sep 18:28

A wasm and kotlin_android correctness release. A wasm engine handle was unusable after one call,
and the kotlin_android e2e suite had never once completed a run. Both traced to the binding
generator, so the fixes arrive via Alef 0.96.0.

Fixed

  • A wasm engine handle survives more than one call. Every generated wasm entry point took
    WasmCrawlEngineHandle by value, and wasm-bindgen's glue for a by-value exported struct calls
    __destroy_into_raw() on it, nulling the JS object's pointer. A second scrape() on the same
    engine threw null pointer passed to rust, and batchScrape consumed the handle identically —
    it only appeared to work because callers used it once. The core API always took a reference and
    the binding body immediately re-borrowed, so the move bought nothing; the Node binding has always
    emitted &JsCrawlEngineHandle from the same IR. The emitted .d.ts is unchanged, so no
    JavaScript or TypeScript caller needs editing. (#56)

  • Transient robots.txt failures no longer block unrelated crawls for five minutes. Sharing the
    robots outcome cache across crawls made one DisallowAll fail-closed for every crawl of that
    origin and user-agent for the full TTL, and the cache could not tell a DNS blip from a WAF
    interstitial. Timeout, connection, DNS and TLS failures never reached the origin and now expire
    after 15 seconds; 5xx, 429 and WAF blocks keep the full five minutes, because backing off there
    is the intended behaviour. The catch-all stays durable, so an unrecognised failure does not get
    both fail-closed and the shortest memory of it. (#55)

  • The kotlin_android e2e suite completes. It had never finished a run: a hung native call ran
    to the job's 90-minute cap, which GitHub records as cancelled rather than failure, so the job
    read as green while testing nothing. Once it completed, 23 failures surfaced that had been latent
    throughout. Generated stream tests deserialized the raw fixture blob into a request DTO that did
    not declare those fields; sealed-class serialization dropped the type discriminator, so the
    native layer rejected every interact call; and generated enums lacked the wire-value
    toString() the assertions compare against. The suite now also logs failures with stack traces
    and times itself out well inside the job cap.

  • The shell formatting CI job runs. It invoked shfmt, which no runner image ships and nothing
    installed, and had exited 127 on every run since 2026-09-15.

Changed

  • Alef pin moved from 0.93.1 to 0.96.0, carrying the generator fixes above.

  • alef.toml now lists the modules alef parses for the API surface. The [[crates]] sources
    paths are read as files and scanned for type definitions; alef does not walk the module graph, so
    a pub use re-export left behind by a file split is invisible to it. path_mappings gained
    entries for the same reason: alef derives a type's import path from the file it was found in,
    which after a split is not where the crate re-exports it.

Notes for wasm callers

config.content.skipImages = true does not work, and never did. wasm-bindgen's getter returns a
detached clone, so the natural idiom mutates a throwaway. Read, modify and assign back:

const c = config.content;
c.skipImages = true;
config.content = c;

The setter consumes its argument, so build a fresh one for the next edit. The same applies to
ssrf, auth, browser and proxy.

Internal

  • CrawlConfig.content now has end-to-end coverage. Of 267 fixtures exactly two set it, one with
    an empty assertion list and the other asserting only batch counts, so a content that was
    ignored entirely passed green in all sixteen generated language suites. Two matched fixtures now
    pin it from opposite directions, and a Rust-level test asserts the same without depending on
    regenerated suites.

  • The size and complexity baseline (#42) goes from 83 findings across 44 files to eight entries,
    each with a stated reason rather than left as debt. Behaviour-preserving throughout: no public or
    crate-visible item changed name, signature, module path or field set. Several of the functions
    restructured had no test that called them at all, so characterization tests were captured against
    the original implementations first.

v1.7.1

Choose a tag to compare

@Goldziher Goldziher released this 16 Sep 17:10

A release-tooling fix. 1.7.0's Java artifact never reached Maven Central; this version carries the
fix and publishes it. No library code changed, so 1.7.0 and 1.7.1 are byte-identical apart from the
version string and the two CI files below.

Fixed

  • Checkstyle's suppressions file is found regardless of where maven is invoked from. checkstyle.xml
    named it by a bare relative path, which checkstyle resolves against the process working directory,
    not against config_loc — and optional="true" meant a miss discarded the entire suppressions
    file in silence. mvn checkstyle:check from packages/java therefore passed while
    mvn -f packages/java/pom.xml from the repo root, which is how the release job invokes it,
    failed on the same bytes. That is what stopped io.xberg.crawlberg:crawlberg:1.7.0 reaching
    Maven Central. Every suppression in the file had been inert in CI for as long as it has existed.
    The path is now anchored to ${config_loc} and the filter is no longer optional, so a missing
    file is an error rather than a silent skip.

  • The publish workflow fails a run that cannot publish. Every publish job gates on
    is_tag == 'true', so a workflow_dispatch carrying a branch as ref skips all of them and
    still reports success. Run 35122273610 skipped 68 jobs that way and went green having published
    nothing, which is indistinguishable from a real success in the run list. is_tag is true in
    every legitimate mode, dry-run included, so refusing a non-tag ref rejects no real dispatch.

Zig

Add to your build.zig.zon:

.dependencies = .{
    .crawlberg-zig = .{\n        .url = \"https://github.com/xberg-io/crawlberg/releases/download/v1.7.1/crawlberg-zig-v1.7.1.tar.gz\",\n        .hash = \"crawlberg-1.7.1-IoY1Cu2HdSKrExssqvYTyzNKFUkwxDJs_0QcH4-15VwQ\",\n    },\n},\n```\n