Repository navigation
Releases
Releases · kerryhatcher/CherryPi-Fetch
v0.3.0
Added
- Markdown output mode for the CLI, library, MCP and Pi tools.
- Linux ARM64 and Windows x86_64 prebuilt targets.
Changed
- Lowered the Linux glibc floor to 2.35 by building on ubuntu-22.04.
- Disabled cargo-binstall strategies on Windows x86_64; use the release ZIP
containing the ANGLE DLLs instead.
v0.2.1
Fixed
- Abandoned renders (dropped futures) now cancel promptly and skip queued
work, worker shutdown rejects queued jobs instead of starting them, and each
render's budget starts when the worker accepts the job rather than when
queued (#17). - Renders no longer settle early while Servo-native page requests (POSTs,
cross-origin fetch, streaming Response bodies, clone/tee/pipeTo/pipeThrough,
XHR, and accessible same-origin child frames) are still in flight, and
NETWORK_QUIET restarts when tracked requests complete (#16). scripts/check-plugin-versions.shnow compares versions with SemVer 2.0.0
section 11 precedence and ASCII-only validation (#22).
v0.2.0
Breaking
- Private, loopback and link-local destinations are refused by default, for
the page and every resource it loads, when they connect (a WebSocket is
resolved again after its check; see the README).localhostand intranet
pages that rendered with 0.1.x now fail.--allow-private(CLI and
cherrypi-fetch mcp) andRendererConfig::allow_private_networksopt out,
for local testing. - Only
httpandhttpsare fetched (data,blobandaboutare allowed
locally; other schemes, includingfile:, are refused). Ports on the Fetch
standard's bad-port list are refused. RendererConfiggained anallow_private_networksfield, so a struct
literal needs updating;RendererConfig::default()is unchanged.
Added
cherrypi-fetch mcp, a stdio MCP server with one tool,fetch_page. It
renders a page in Servo and returns its title and text. Invalid input and a
failed render are tool errors (isError). The server is behind themcp
feature, which is on by default.--no-default-features --features cli
builds the command without it.- Agent plugins for Claude Code and Codex (an MCP server entry plus a skill),
and a Pi package (afetch_pageextension plus the skill). They install from
this repository's marketplaces; see "Use it from your agent" in the README. strip_userinfois public, so a caller can strip credentials the same way
the CLI does.
Changed
- Servo's own connections go through a checking proxy. Each connection is
checked when it is made, and connects only to the address it checked, so
DNS rebinding no longer moves a connection to a private address. Servo
follows redirects itself, and every hop goes through the proxy. Proxy
environment variables are ignored; they used to make the render fail. - URL userinfo (
user:pass@) is stripped from the input URL by the CLI,
render_pageandfetch_page, and never appears in their output. A load
whose URL still carries it, such as a subresource the page names, is
refused. Redirect targets that Servo follows itself are not covered; see the
README. - Same-origin script requests, which this crate fetches itself, decode gzip,
brotli, deflate and zstd bodies. Their redirects send each hop the page's
cookies for that URL and store each hop'sSet-Cookie. A redirect that
leaves the origin is a network error (#19). - Redirect statuses: only 301, 302, 303, 307 and 308 with a
Locationare
redirects. Other responses, such as a 300 or a 304, reach the page as they
are. fetch_pageclamps anymax_charsabove 200000, however large.rmcpis a caret requirement (3.12), so library users are not pinned to
one patch release. Install withcargo install --lockedto build with the
versions inCargo.lock.- The non-default
test-hooksfeature is now__test-hooks.
Fixed
- A page whose main document fails to load (connection refused, DNS failure,
a bad port, or a TLS error) is a failed render:RenderError::Failedwith
Servo's reason,ok:falseand exit 1 from the CLI, andisErrorfrom MCP.
It used to come back asok:truewith Servo's error page as the text. cherrypi-fetch mcpexits on SIGTERM or SIGINT while its client keeps stdin
open. It waits at most two seconds for the service to stop, then stops
Servo. A render already in progress still finishes first, and the server
logs that to stderr.- A call that is cancelled while it waits for the renderer no longer renders
the page once its turn comes. A render that has started still runs to its
end, because Servo cannot abort a load. cherrypi-fetch --json mcp(an option beforemcp) explains thatmcpis a
subcommand, rather than reporting an invalid URL.- The
fetch_pageinput schema states the ranges and defaults, and whole
numbers sent as floats (20.0) are accepted.
v0.1.1
Fixed
- The proxy's script requests follow Servo and trust the system root store
(rustls-tls-native-roots-no-provider), and HTTP/2 is enabled. A page
behind a corporate or custom CA no longer renders incomplete because its
proxied requests fail TLS.
v0.1.0
Initial release: the cherrypi-fetch library and CLI, moved out of CherryPi's
crates/servo-fetch into their own crate.
Added
cherrypi-fetchas a library and as acherrypi-fetchcommand. The API is
render_page, with a process-wideconfigurefor the User-Agent and a
shutdown_rendererfor a clean exit.- The renderer behaviour that lived in CherryPi:
- same-origin GET requests from scripts (XHR and
fetch) are proxied
throughreqwestwith an 8-second timeout; other requests are left to
Servo. A render that still stalls ends at its timeout: it is returned as
incomplete if it captured some text, or fails (ok:false, exit 1) if it
captured none; - cookies, local and session storage and the HTTP cache are cleared before
every render, so one bot block cannot poison the next; - a configurable User-Agent, defaulting to Windows Firefox, because some
sites never answer a desktop Linux user agent; - snapshots that are discarded when a navigation starts, so text from an
earlier document does not leak through; - one Servo instance per process, on its own thread, ended by
shutdown_renderer; - timeouts bounded to 1–600 seconds;
--max-charstruncates text on
request.
- same-origin GET requests from scripts (XHR and
- Page titles and text are stripped of C0 and C1 control characters other
than newline and tab, and of the bidi overrides and isolates, so a page
cannot inject terminal escapes or reorder a caller's output. - CLI
--jsonrecords and exit codes: 0 when every page rendered fully, 1
when at least one failed (even if others were incomplete) or the arguments
were bad, 2 when at least one was incomplete and none failed.