• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

sgerrand / ex_humaans / 25314888639 / 1
99%
main: 99%

Build:
DEFAULT BRANCH: main
Ran 04 May 2026 10:51AM UTC
Files 17
Run time 0s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

04 May 2026 10:50AM UTC coverage: 100.0%. Remained the same
25314888639.1

push

github

web-flow
feat(http_client): pass-through req_options on Humaans.new/1 (#89)

* feat(http_client): pass-through req_options on Humaans.new/1

Most callers customising the default Req client only want to tweak
timeouts, retries, or plugins — not rewrite the entire request
pipeline. Previously this required implementing the full
Humaans.HTTPClient.Behaviour. The new :req_options option is merged
into the base Req config, so the common case becomes a one-liner:

    Humaans.new(
      access_token: "...",
      req_options: [connect_options: [timeout: 30_000], retry: :transient]
    )

The behaviour-based escape hatch is still available for callers that
need full control.

* fix(http_client): prevent req_options from overriding :base_url and :auth

A user-supplied :base_url or :auth in req_options could redirect requests
or leak the bearer token to an unintended host. Reverse the merge so the
client's values always win, and explicitly drop those keys from
req_options. Also coerce a nil :req_options to [] for structs built
directly.

* feat(humaans): validate :req_options in Humaans.new/1

:req_options is documented as a keyword list, but new/1 previously
accepted any value and stored it in the struct, deferring failures to
Keyword.merge/2 inside the request pipeline. Validate up-front: coerce
nil to [] and raise ArgumentError with a clear message for any other
non-keyword-list value.

159 of 159 relevant lines covered (100.0%)

19.47 hits per line

Source Files on job 25314888639.1
  • Tree
  • List 17
  • Changed 2
  • Source Changed 2
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 25314888639
  • 48f9c594 on github
  • Prev Job for on main (#25313910988.1)
  • Next Job for on main (#25315925198.1)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc