kubo/core/node
Guillaume Michel 6fcbba4b4a
fix: allow custom http provide when libp2p node is offline (#10974)
* feat: allow custom http provide when offline

* refactor: improve offline HTTP provider handling and tests

- fixed comment/function name mismatch
- added mock server test for HTTP provide success
- clarified test names for offline scenarios

* test: simplify single-node provider tests

use h.NewNode().Init() instead of NewNodes(1) for cleaner test setup

* fix: allow SweepingProvider to work with HTTP-only routing

when no DHT is available but HTTP routers are configured for providing,
return NoopProvider instead of failing. this allows the daemon to start
and HTTP-based providing to work through the routing system.

moved HTTP provider detection to config package as HasHTTPProviderConfigured()
for better code organization and reusability.

this fix is important as SweepingProvider will become the new default in the future.

---------

Co-authored-by: Marcin Rataj <lidel@lidel.org>
2025-09-19 18:55:42 +02:00
..
helpers collection of typo fixes (#10647) 2024-12-29 21:27:41 -08:00
libp2p refactor(ci): optimize build workflows (#10973) 2025-09-19 14:44:38 +02:00
bitswap.go fix: Provide according to Reprovider.Strategy (#10886) 2025-08-08 10:56:44 +02:00
builder.go feat(config): AutoConf with "auto" placeholders (#10883) 2025-08-20 05:59:11 +02:00
core.go fix(mfs): unbound cache growth with flush=false (#10971) 2025-09-19 03:39:55 +02:00
dns.go feat(config): AutoConf with "auto" placeholders (#10883) 2025-08-20 05:59:11 +02:00
groups.go docs(provide): validation and reprovide cycle visualization (#10977) 2025-09-19 18:47:30 +02:00
helpers.go refactor: remove goprocess (#10872) 2025-08-06 00:33:45 +02:00
identity.go chore: bump go-libp2p v0.22.0 & go1.18&go1.19 2022-09-09 17:09:38 +02:00
ipns.go refactor: update to boxo without goprocess (#10567) 2024-11-19 18:04:22 +01:00
peering.go chore: migrate peering to ipfs/boxo (#10157) 2023-10-31 13:45:51 +00:00
provider.go fix: allow custom http provide when libp2p node is offline (#10974) 2025-09-19 18:55:42 +02:00
storage.go refactor(config): migration 17-to-18 to unify Provider/Reprovider into Provide.DHT (#10951) 2025-09-18 22:17:43 +02:00