gears icon indicating copy to clipboard operation
gears copied to clipboard

[DISCUSSION]: Replace panic from RocksDB

Open NYBACHOK opened this issue 7 months ago • 0 comments

Original comment:

  fn get(&self, key: &[u8]) -> Option<Vec<u8>> {
        self.db
            .get(key)
            .unwrap_or_else(|e| panic!("unrecoverable database error {}", e)) //TODO: this is probably 
// not the right thing to do when handling a abci or REST query. Perhaps we should have a must_get method?
    }

We need to re-think is it correct to panic if no value found in db

NYBACHOK avatar Jul 12 '24 09:07 NYBACHOK