errs

package
v0.0.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 4, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrCrawlNotFound            = errors.New("crawl not found")
	ErrCoverDownLoadZeroSize    = errors.New("cover file downloader zero size after multiple attempts")
	ErrUnknownResCrawlLsType    = errors.New("unknown resource ls crawl type")
	ErrLsGroupUnavailableOnTorr = errors.New("command `ls group` is unavailableOnTorrent type")

	ErrBgmTVApiPrefix = errors.New("bgmTV api")

	ErrTorrentNotFound           = errors.New("there are no torrent files on qbt")
	ErrTorrentOnSavePathNotFound = errors.New("there are no torrent files on savepath of a subject")
	ErrQbtDataNotFound           = errors.New("no data found from the api request (should be found)")
	ErrSubjectAlreadyExisted     = errors.New("subject already existed")
	ErrSubjectNotFound           = errors.New("subject not found")
	ErrBgmUrlNotFoundOnMikan     = errors.New("bgm url not found on anicat")
	ErrUndefinedCrawlListType    = errors.New("undefined crawl list type")
	WarnRssRuleNotMatched        = errors.New("there is no any series mached,check your auto-downloader rule")

	ErrCannotCaptureEpisNum = errors.New("can not capture episode num from text")
	ErrItemAlreadyPushed    = errors.New("item was already pushed")
	ErrNoLinkFoundOnRssFeed = errors.New("can not found link on feed")
)

Functions

func Custom

func Custom(format string, a ...any) error

func ErrTransfer

func ErrTransfer(src error, dst *error)

func HasError

func HasError(t *testing.T, err error, message ...string)

func NoError

func NoError(t *testing.T, err error, message ...string)

func PanicErr

func PanicErr(err error, ef func())

func PanicRedirect added in v0.0.6

func PanicRedirect(file *os.File) error

func RequireNonErr

func RequireNonErr(err error) bool

Types

type ErrWrapper

type ErrWrapper struct {
	// contains filtered or unexported fields
}

func (*ErrWrapper) Error

func (wp *ErrWrapper) Error() error

func (*ErrWrapper) Handle

func (wp *ErrWrapper) Handle(t Thrower)

func (*ErrWrapper) Reset

func (wp *ErrWrapper) Reset()

type MultiErr

type MultiErr struct {
	// contains filtered or unexported fields
}

func (*MultiErr) Add

func (me *MultiErr) Add(e error)

func (*MultiErr) Err

func (me *MultiErr) Err() error

type Thrower

type Thrower func() error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL