v0.1.0 — first release
·
38 commits
to main
since this release
Immutable
release. Only release title and notes can be modified.
First tagged release of gosearch.
Zero-API-key web search for local-first Go programs: Search() queries Google, Yandex, or DuckDuckGo by fetching and parsing each engine's public HTML result page; Fetch() extracts the readable main content of any URL. The only third-party dependency is golang.org/x/net/html.
go get github.com/BugraAkdemir/gosearch@v0.1.0Highlights
- Three engines, one interface — ordered fallback via
WithFallback(...); advances only onErrBlocked/ErrChallenge, never on a valid empty result. - Honest anti-bot handling — realistic browser headers, cookie jar, per-host rate limiting, and block detection (
ErrBlocked/ErrChallenge); no CAPTCHA solving, JS-challenge execution, or proxy rotation — ever. - Retries where they help — transient failures (network errors, HTTP 408/5xx) retried with exponential backoff (
WithRetries(n), default 2). - Readable content extraction —
Fetch()returns title + main text with nav/ads/footer stripped.
Reliability, honestly
- DuckDuckGo — validated against a real captured success page; most reliable of the three.
- Google / Yandex — best-effort heuristics against documented markup, tested offline on synthetic + real block fixtures; these engines serve result pages only to clients they trust, so reliability is IP-reputation dependent.
Notes
- Tests are offline and deterministic;
go test ./...never contacts the live engines. - CI runs build, vet, gofmt, golangci-lint, and
go test -raceon every push.