go-ethereum/ethdb
Ocenka ec6d104404
eth/remotedb: improve error handling (#31331)
This PR improves error handling in the remotedb package by fixing two
issues:

1. In the `Has` method, we now properly propagate errors instead of
silently returning false. This makes the behavior more predictable and
helps clients better understand when there are connection issues.

2. In the `New` constructor, we add a nil check for the client parameter
to prevent potential panics. This follows Go best practices for
constructor functions.

These changes make the code more robust and follow Go's error handling
idioms without requiring any changes to other parts of the codebase.

Changes:
- Modified `Has` method to return errors instead of silently returning
false
- Added nil check in `New` constructor
- Fixed field name in constructor to match struct definition
2025-04-08 14:44:13 +02:00
..
dbtest ethdb: add DeleteRange feature (#30668) 2024-10-25 17:33:46 +02:00
leveldb core/filtermaps: hashdb safe delete range (#31525) 2025-03-31 14:47:56 +02:00
memorydb ethdb/memorydb: faster DeleteRange (#31038) 2025-01-17 16:54:19 +01:00
pebble core, eth, node: use sync write option in pebble (#31519) 2025-04-03 16:03:03 +02:00
remotedb eth/remotedb: improve error handling (#31331) 2025-04-08 14:44:13 +02:00
batch.go core, ethdb, tests, trie: implement NewBatchWithSize API for batcher (#24392) 2022-02-15 15:15:13 +02:00
database.go core/filtermaps: hashdb safe delete range (#31525) 2025-03-31 14:47:56 +02:00
iterator.go all: simplify and fix database iteration with prefix/start (#20808) 2020-04-15 14:08:53 +03:00