errors

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Jun 18, 2021 License: MIT Imports: 1 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	// CreateTaskError represents an error that occurs when creating a new task
	CreateTaskError = "error creating new task"
	// DeleteTaskError represents an error that occurs when deleting a task
	DeleteTaskError = "error deleting task"
	// ListTaskError represents an error that occurs when listing tasks
	ListTaskError = "error listing tasks"
	// SearchTaskError represents an error that occurs when searching for tasks
	SearchTaskError = "error searching for tasks"
	// LoadTaskError represents an error that occurs when loading a task
	LoadTaskError = "error loading task"
	// StopRunningTaskError represents an error that occurs when stopping the running task
	StopRunningTaskError = "error stopping the running task"
	// UpdateDeletedTaskError represents an error that occurs when updating a deleted task
	UpdateDeletedTaskError = "cannot update a deleted task"
	// UndeleteTaskError represents an error that occurs when undeleting a task
	UndeleteTaskError = "error undeleting task"
	// UpdateTaskError represents an error that occurs when updating a task
	UpdateTaskError = "error updating task"
	// NoRunningTasksError represents an error that occurs when a running task was expected but not found
	NoRunningTasksError = "a task is not running"
	// OverwriteTaskByCreateError represents an error that occurs when a task is about to be overwritten by creating it again
	OverwriteTaskByCreateError = "cannot overwrite a task by creating it"
	// LoadInvalidTaskError represents an error that occurs when an attempt is made to load a task with an invalid (nonexistant) ID
	LoadInvalidTaskError = "cannot load a task that does not exist"
	// UpdateInvalidTaskError represents an error that occurs when an attempt is made to update a task with an invalid (nonexistant) ID
	UpdateInvalidTaskError = "cannot update a task that does not exist"
	// DeleteInvalidTaskError represents an error that occurs when an attempt is made to delete a task with an invalid (nonexistant) ID
	DeleteInvalidTaskError = "cannot delete a task that does not exist"
	// EmptySynopsisTaskError represents an error that occurs when a task synopsis was expected but not found
	EmptySynopsisTaskError = "cannot create a task with an empty synopsis"
	// UpdateEmptySynopsisTaskError represents an error that occurs when an attempt is made to update an existing task to have an empty synopsis
	UpdateEmptySynopsisTaskError = "cannot update a task to have an empty synopsis"
)
View Source
const (
	// CreateTimesheetError represents an error that occurs when creating a timesheet
	CreateTimesheetError = "error creating timesheet"

	// OverwriteTimesheetByCreateError represents an error that occurs when a timesheet is about to be overwritten by creating it again
	OverwriteTimesheetByCreateError = "cannot overwrite a timesheet by creating it"
	// TimesheetWithoutTaskError represents an error that occurs when executing an operation on a timesheet that does not have a linked task
	TimesheetWithoutTaskError = "no task is associated with the timesheet"
	// ListTimesheetError represents an error that occurs when timesheets are listed
	ListTimesheetError = "error listing timesheets"
	// LoadInvalidTimesheetError represents an error that occurs when an attempt is made to load a timesheet with an invalid (nonexistant) ID
	LoadInvalidTimesheetError = "cannot load a timesheet that does not exist"
	// UpdateInvalidTimesheetError represents an error that occurs when an attempt is made to update a timesheet with an invalid (nonexistant) ID
	UpdateInvalidTimesheetError = "cannot update a timesheet that does not exist"
	// DeleteInvalidTimesheetError represents an error that occurs when an attempt is made to delete a timesheet with an invalid (nonexistant) ID
	DeleteInvalidTimesheetError = "cannot delete a timesheet that does not exist"
)
View Source
const (
	// ScanNowIntoSQLNullTimeError describes an error that occurs when scanning time.Now() into a sql.NullTime object
	ScanNowIntoSQLNullTimeError = "error scanning time.Now() into sql.NullTime"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ErrInvalidTaskState

type ErrInvalidTaskState struct {
	Details string
}

ErrInvalidTaskState represents an error that occurs when a task is in an invalid state

func (ErrInvalidTaskState) Error

func (e ErrInvalidTaskState) Error() string

type ErrInvalidTimesheetState

type ErrInvalidTimesheetState struct {
	// Details is any extra information related to the error
	Details string
}

ErrInvalidTimesheetState represents an error that occurs when an timesheet is in an invalid state

func (ErrInvalidTimesheetState) Error

func (e ErrInvalidTimesheetState) Error() string

type ErrNoRunningTask

type ErrNoRunningTask struct{}

ErrNoRunningTask represents an error that occurs when a running task was expected but not found

func (ErrNoRunningTask) Error

func (e ErrNoRunningTask) Error() string

type ErrPidfileNotFound

type ErrPidfileNotFound struct {
	PidfilePath string
}

func (*ErrPidfileNotFound) Error

func (e *ErrPidfileNotFound) Error() string

type ErrScanNowIntoSQLNull

type ErrScanNowIntoSQLNull struct {
	// Wrapped is a wrapped error
	Wrapped error
}

ErrScanNowIntoSQLNull represents an error that occurs when scanning time.Now() into a sql.NullTime object

func (ErrScanNowIntoSQLNull) Error

func (e ErrScanNowIntoSQLNull) Error() string

func (ErrScanNowIntoSQLNull) Unwrap

func (e ErrScanNowIntoSQLNull) Unwrap() error

Unwrap implements a wrapped error

Jump to

Keyboard shortcuts

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