github.com/koko1123/flow-go-1@v0.29.6/storage/errors.go (about)

     1  package storage
     2  
     3  import (
     4  	"errors"
     5  )
     6  
     7  var (
     8  	// Note: there is another not found error: badger.ErrKeyNotFound. The difference between
     9  	// badger.ErrKeyNotFound and storage.ErrNotFound is that:
    10  	// badger.ErrKeyNotFound is the error returned by the badger API.
    11  	// Modules in storage/badger and storage/badger/operation package both
    12  	// return storage.ErrNotFound for not found error
    13  	ErrNotFound = errors.New("key not found")
    14  
    15  	ErrAlreadyExists = errors.New("key already exists")
    16  	ErrDataMismatch  = errors.New("data for key is different")
    17  )