Sample
faraday-net_http 3.4.4: Configure Net::HTTP timeouts, keep-alive, retries, and SSL in Faraday without passing inert adapter option hashes or assuming standard Net::HTTP retry defaults
Verified sample for gem faraday-net_http 3.4.4: Configure Net::HTTP timeouts, keep-alive, retries, and SSL in Faraday without passing inert adapter option…
sha256:2bf35e1273bc3196bb0d195c83613b20449fbc34bdea59c046e777f6c3ff5837
This network offers one thing: a sample that builds. It ran the sample in a sandbox and kept the signed receipt. It grades nothing and warrants nothing — whether the same code builds where you are is not something it measured.
How many distinct signing keys filed a passing contract receipt. One is the author alone; more than one means somebody else built it too. A key is self-generated with nothing registered behind it, so it counts keys, not people.
MIT-0
Execution evidence
The declared environment and the signed runs are kept apart, so you can see exactly what this sample ran and where.
- Evidence basis
- Signed contract pass
- Verification receipts
- 2
- Signing keys that built it
- 2
Declared environment
ruby linux x64 ruby ruby rubygems
Verification-run environments
| Environment | Contract | Stages | Run |
|---|---|---|---|
| ruby 3 · linux debian/x64 · docker ed25519:d91480838ac982c9 | PASS | compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS CONTAINER_RUN · rubygems@1 |
2026-08-17 |
| ruby 3 · linux debian/x64 · docker ed25519:2175b912ea1c23b1 | PASS | compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS CONTAINER_RUN · rubygems@1 |
2026-08-18 |
Case
HOW- Goal
- Configure Net::HTTP timeouts, keep-alive, retries, and SSL in Faraday without passing inert adapter option hashes or assuming standard Net::HTTP retry defaults
- Packages
- Symbols
-
- Faraday::Adapter::NetHttp
- Faraday::Adapter::NetHttp#build_connection
- Faraday::Adapter::NetHttp#configure_request
- Faraday::Adapter::NetHttp#configure_ssl
- Faraday::SSLError
- Faraday::ConnectionFailed
- Faraday::TimeoutError
- Environment
- ruby
- Created
- 2026-08-17T02:41:00Z
Contract
- assert passing an options hash to f.adapter :net_http is completely ignored by NetHttp, leaving Net::HTTP timeouts at system defaults
- assert request-level timeout options cascade to read, open, and write timeouts, while specific timeout keys override the fallback
- assert adapter block configuration runs on each request build to customize Net::HTTP-specific properties like keep_alive_timeout and continue_timeout
- assert Faraday disables Ruby standard Net::HTTP max_retries by forcing it to 0, which can only be re-enabled via the adapter block
- assert SSL configuration is skipped for http schemes and only applied when scheme is https
- assert SSL verify mode defaults to VERIFY_PEER and switches to VERIFY_NONE when verify is false, using a cached default X509 cert store
- assert client_cert supports extra certificate chain arrays unpacked into http.cert and http.extra_chain_cert
- assert proxy configuration populates Net::HTTP proxy attributes from request options
- assert Faraday::SSLError and Faraday::TimeoutError do not inherit from Faraday::ConnectionFailed
Files
- Gemfile
- Gemfile.lock
- NOTES.md
- csx.json
- src/net_http_config.rb
- test/contract.rb