v1.2.1

Removed APIs

Last updated


This page lists exported identifiers that no longer exist, the version that removed them, and what to use instead.

Root Package Moved to core


v1.2.1 moved the scheduler from the module root (package goCron) to github.com/pardnchiu/go-scheduler/core (package core). Every identifier below still exists under core with the same signature, except List.
SymbolPackageRemovedLast availableReplacement
Newmodule rootRemoved in v1.2.1v1.2.0core.New
Configmodule rootRemoved in v1.2.1v1.2.0core.Config
Waitmodule rootRemoved in v1.2.1v1.2.0core.Wait
WaitStatemodule rootRemoved in v1.2.1v1.2.0core.WaitState
Stop, Skip constantsmodule rootRemoved in v1.2.1v1.2.0core.Stop, core.Skip
TaskPending, TaskRunning, TaskCompleted, TaskFailedmodule rootRemoved in v1.2.1v1.2.0core.TaskPending and siblings
Start methodmodule rootRemoved in v1.2.1v1.2.0Start on the value returned by core.New
Stop methodmodule rootRemoved in v1.2.1v1.2.0Stop on the value returned by core.New
Add methodmodule rootRemoved in v1.2.1v1.2.0Add on the value returned by core.New
Remove methodmodule rootRemoved in v1.2.1v1.2.0Remove on the value returned by core.New
RemoveAll methodmodule rootRemoved in v1.2.1v1.2.0RemoveAll on the value returned by core.New
List method returning []taskmodule rootRemoved in v1.2.1v1.2.0List on the value returned by core.New, now returning []*task
Len, Less, Swap, Push, Pop on taskHeapmodule rootRemoved in v1.2.1v1.2.0No public replacement; internal container/heap implementation

  1. // before v1.2.1
  2. import cron "github.com/pardnchiu/go-scheduler"
  3. scheduler, err := cron.New(cron.Config{Location: time.Local})
  4. // v1.2.1 and later
  5. import "github.com/pardnchiu/go-scheduler/core"
  6. scheduler, err := core.New(core.Config{Location: time.Local})

Custom Logger


SymbolPackageRemovedLast availableReplacement
Log type (alias of go-logger Log)module rootRemoved in v0.3.1v0.3.0No public replacement; logging uses log/slog internally
Logger type (alias of go-logger Logger)module rootRemoved in v0.3.1v0.3.0No public replacement
Config.Log fieldmodule rootRemoved in v0.3.1v0.3.0No public replacement; see Configuration for the fixed logger

See Released for the full changelog of each version.
中文