backtest-kit 3.3.2 → 3.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/types.d.ts CHANGED
@@ -57,6 +57,23 @@ declare const ExecutionContextService: (new () => {
57
57
  */
58
58
  type TExecutionContextService = InstanceType<typeof ExecutionContextService>;
59
59
 
60
+ /**
61
+ * Single log entry stored in the log history.
62
+ */
63
+ interface ILogEntry {
64
+ /** Unique entry identifier generated via randomString */
65
+ id: string;
66
+ /** Log level */
67
+ type: "log" | "debug" | "info" | "warn";
68
+ /** Unix timestamp in milliseconds when the entry was created */
69
+ timestamp: number;
70
+ /** Date taken from backtest context to improve user experience */
71
+ createdAt: string;
72
+ /** Log topic / method name */
73
+ topic: string;
74
+ /** Additional arguments passed to the log call */
75
+ args: unknown[];
76
+ }
60
77
  /**
61
78
  * Interface representing a logging mechanism for the swarm system.
62
79
  * Provides methods to record messages at different severity levels, used across components like agents, sessions, states, storage, swarms, history, embeddings, completions, and policies.
@@ -89,6 +106,22 @@ interface ILogger {
89
106
  * Candle time interval for fetching historical data.
90
107
  */
91
108
  type CandleInterval = "1m" | "3m" | "5m" | "15m" | "30m" | "1h" | "2h" | "4h" | "6h" | "8h";
109
+ /** Numeric type that can be undefined (used for optional numeric values) */
110
+ type Num = number | undefined;
111
+ interface IPublicCandleData {
112
+ /** Unix timestamp in milliseconds when candle opened */
113
+ timestamp: Num;
114
+ /** Opening price at candle start */
115
+ open: Num;
116
+ /** Highest price during candle period */
117
+ high: Num;
118
+ /** Lowest price during candle period */
119
+ low: Num;
120
+ /** Closing price at candle end */
121
+ close: Num;
122
+ /** Trading volume during candle period */
123
+ volume: Num;
124
+ }
92
125
  /**
93
126
  * Single OHLCV candle data point.
94
127
  * Used for VWAP calculation and backtesting.
@@ -172,7 +205,7 @@ interface IExchangeSchema {
172
205
  * @param backtest - Whether running in backtest mode
173
206
  * @returns Promise resolving to array of OHLCV candle data
174
207
  */
175
- getCandles: (symbol: string, interval: CandleInterval, since: Date, limit: number, backtest: boolean) => Promise<ICandleData[]>;
208
+ getCandles: (symbol: string, interval: CandleInterval, since: Date, limit: number, backtest: boolean) => Promise<IPublicCandleData[]>;
176
209
  /**
177
210
  * Format quantity according to exchange precision rules.
178
211
  *
@@ -4363,6 +4396,14 @@ declare const GLOBAL_CONFIG: {
4363
4396
  * Default: 50 signals
4364
4397
  */
4365
4398
  CC_MAX_SIGNALS: number;
4399
+ /**
4400
+ * Maximum number of log lines to keep in storage.
4401
+ * Older log lines are removed when this limit is exceeded.
4402
+ * This helps prevent unbounded log growth which can consume memory and degrade performance over time.
4403
+ *
4404
+ * Default: 1000 log lines
4405
+ */
4406
+ CC_MAX_LOG_LINES: number;
4366
4407
  /**
4367
4408
  * Enables mutex locking for candle fetching to prevent concurrent fetches of the same candles.
4368
4409
  * This can help avoid redundant API calls and ensure data consistency when multiple processes/threads attempt to fetch candles simultaneously.
@@ -4478,6 +4519,7 @@ declare function getConfig(): {
4478
4519
  CC_ORDER_BOOK_MAX_DEPTH_LEVELS: number;
4479
4520
  CC_MAX_NOTIFICATIONS: number;
4480
4521
  CC_MAX_SIGNALS: number;
4522
+ CC_MAX_LOG_LINES: number;
4481
4523
  CC_ENABLE_CANDLE_FETCH_MUTEX: boolean;
4482
4524
  };
4483
4525
  /**
@@ -4515,6 +4557,7 @@ declare function getDefaultConfig(): Readonly<{
4515
4557
  CC_ORDER_BOOK_MAX_DEPTH_LEVELS: number;
4516
4558
  CC_MAX_NOTIFICATIONS: number;
4517
4559
  CC_MAX_SIGNALS: number;
4560
+ CC_MAX_LOG_LINES: number;
4518
4561
  CC_ENABLE_CANDLE_FETCH_MUTEX: boolean;
4519
4562
  }>;
4520
4563
  /**
@@ -9112,6 +9155,71 @@ declare class PersistNotificationUtils {
9112
9155
  */
9113
9156
  declare const PersistNotificationAdapter: PersistNotificationUtils;
9114
9157
 
9158
+ /**
9159
+ * Type for persisted log data.
9160
+ * Each log entry is stored as a separate file keyed by its id.
9161
+ */
9162
+ type LogData = ILogEntry[];
9163
+ /**
9164
+ * Utility class for managing log entry persistence.
9165
+ *
9166
+ * Features:
9167
+ * - Memoized storage instance
9168
+ * - Custom adapter support
9169
+ * - Atomic read/write operations for LogData
9170
+ * - Each log entry stored as separate file keyed by id
9171
+ * - Crash-safe log state management
9172
+ *
9173
+ * Used by LogPersistUtils for log entry persistence.
9174
+ */
9175
+ declare class PersistLogUtils {
9176
+ private PersistLogFactory;
9177
+ private _logStorage;
9178
+ private getLogStorage;
9179
+ /**
9180
+ * Registers a custom persistence adapter.
9181
+ *
9182
+ * @param Ctor - Custom PersistBase constructor
9183
+ */
9184
+ usePersistLogAdapter(Ctor: TPersistBaseCtor<string, ILogEntry>): void;
9185
+ /**
9186
+ * Reads persisted log entries.
9187
+ *
9188
+ * Called by LogPersistUtils.waitForInit() to restore state.
9189
+ * Uses keys() from PersistBase to iterate over all stored entries.
9190
+ * Returns empty array if no entries exist.
9191
+ *
9192
+ * @returns Promise resolving to array of log entries
9193
+ */
9194
+ readLogData: () => Promise<LogData>;
9195
+ /**
9196
+ * Writes log entries to disk with atomic file writes.
9197
+ *
9198
+ * Called by LogPersistUtils after each log call to persist state.
9199
+ * Uses entry.id as the storage key for individual file storage.
9200
+ * Uses atomic writes to prevent corruption on crashes.
9201
+ *
9202
+ * @param logData - Log entries to persist
9203
+ * @returns Promise that resolves when write is complete
9204
+ */
9205
+ writeLogData: (logData: LogData) => Promise<void>;
9206
+ /**
9207
+ * Switches to the default JSON persist adapter.
9208
+ * All future persistence writes will use JSON storage.
9209
+ */
9210
+ useJson(): void;
9211
+ /**
9212
+ * Switches to a dummy persist adapter that discards all writes.
9213
+ * All future persistence writes will be no-ops.
9214
+ */
9215
+ useDummy(): void;
9216
+ }
9217
+ /**
9218
+ * Global singleton instance of PersistLogUtils.
9219
+ * Used by LogPersistUtils for log entry persistence.
9220
+ */
9221
+ declare const PersistLogAdapter: PersistLogUtils;
9222
+
9115
9223
  declare const WAIT_FOR_INIT_SYMBOL$1: unique symbol;
9116
9224
  declare const WRITE_SAFE_SYMBOL$1: unique symbol;
9117
9225
  /**
@@ -9721,6 +9829,95 @@ declare class MarkdownAdapter extends MarkdownUtils {
9721
9829
  */
9722
9830
  declare const Markdown: MarkdownAdapter;
9723
9831
 
9832
+ /**
9833
+ * Extended logger interface with log history access.
9834
+ */
9835
+ interface ILog extends ILogger {
9836
+ /**
9837
+ * Returns all stored log entries.
9838
+ * @returns Array of all log entries
9839
+ */
9840
+ getList(): Promise<ILogEntry[]>;
9841
+ }
9842
+ /**
9843
+ * Constructor type for log adapters.
9844
+ * Used for custom log implementations.
9845
+ */
9846
+ type TLogCtor = new () => Partial<ILog>;
9847
+ /**
9848
+ * Log adapter with pluggable storage backend.
9849
+ *
9850
+ * Features:
9851
+ * - Adapter pattern for swappable log implementations
9852
+ * - Default adapter: LogMemoryUtils (in-memory storage)
9853
+ * - Alternative adapters: LogPersistUtils, LogDummyUtils
9854
+ * - Convenience methods: usePersist(), useMemory(), useDummy()
9855
+ */
9856
+ declare class LogAdapter implements ILog {
9857
+ /** Internal log utils instance */
9858
+ private _log;
9859
+ /**
9860
+ * Lists all stored log entries.
9861
+ * Proxies call to the underlying log adapter.
9862
+ * @returns Array of all log entries
9863
+ */
9864
+ getList: () => Promise<ILogEntry[]>;
9865
+ /**
9866
+ * Logs a general-purpose message.
9867
+ * Proxies call to the underlying log adapter.
9868
+ * @param topic - The log topic / method name
9869
+ * @param args - Additional arguments
9870
+ */
9871
+ log: (topic: string, ...args: any[]) => void;
9872
+ /**
9873
+ * Logs a debug-level message.
9874
+ * Proxies call to the underlying log adapter.
9875
+ * @param topic - The log topic / method name
9876
+ * @param args - Additional arguments
9877
+ */
9878
+ debug: (topic: string, ...args: any[]) => void;
9879
+ /**
9880
+ * Logs an info-level message.
9881
+ * Proxies call to the underlying log adapter.
9882
+ * @param topic - The log topic / method name
9883
+ * @param args - Additional arguments
9884
+ */
9885
+ info: (topic: string, ...args: any[]) => void;
9886
+ /**
9887
+ * Logs a warning-level message.
9888
+ * Proxies call to the underlying log adapter.
9889
+ * @param topic - The log topic / method name
9890
+ * @param args - Additional arguments
9891
+ */
9892
+ warn: (topic: string, ...args: any[]) => void;
9893
+ /**
9894
+ * Sets the log adapter constructor.
9895
+ * All future log operations will use this adapter.
9896
+ * @param Ctor - Constructor for log adapter
9897
+ */
9898
+ useLogger: (Ctor: TLogCtor) => void;
9899
+ /**
9900
+ * Switches to persistent log adapter.
9901
+ * Log entries will be persisted to disk.
9902
+ */
9903
+ usePersist: () => void;
9904
+ /**
9905
+ * Switches to in-memory log adapter (default).
9906
+ * Log entries will be stored in memory only.
9907
+ */
9908
+ useMemory: () => void;
9909
+ /**
9910
+ * Switches to dummy log adapter.
9911
+ * All future log writes will be no-ops.
9912
+ */
9913
+ useDummy: () => void;
9914
+ }
9915
+ /**
9916
+ * Global singleton instance of LogAdapter.
9917
+ * Provides unified log management with pluggable backends.
9918
+ */
9919
+ declare const Log: LogAdapter;
9920
+
9724
9921
  /**
9725
9922
  * Type alias for column configuration used in backtest markdown reports.
9726
9923
  *
@@ -21255,4 +21452,4 @@ declare const backtest: {
21255
21452
  loggerService: LoggerService;
21256
21453
  };
21257
21454
 
21258
- export { ActionBase, type ActivateScheduledCommit, type ActivateScheduledCommitNotification, type ActivePingContract, type AverageBuyCommit, Backtest, type BacktestStatisticsModel, Breakeven, type BreakevenAvailableNotification, type BreakevenCommit, type BreakevenCommitNotification, type BreakevenContract, type BreakevenData, Cache, type CancelScheduledCommit, type CandleData, type CandleInterval, type ClosePendingCommit, type ColumnConfig, type ColumnModel, Constant, type CriticalErrorNotification, type DoneContract, type EntityId, Exchange, ExecutionContextService, type FrameInterval, type GlobalConfig, Heat, type HeatmapStatisticsModel, type IActionSchema, type IActivateScheduledCommitRow, type IBidData, type IBreakevenCommitRow, type ICandleData, type ICommitRow, type IExchangeSchema, type IFrameSchema, type IHeatmapRow, type IMarkdownDumpOptions, type INotificationUtils, type IOrderBookData, type IPartialLossCommitRow, type IPartialProfitCommitRow, type IPersistBase, type IPositionSizeATRParams, type IPositionSizeFixedPercentageParams, type IPositionSizeKellyParams, type IPublicAction, type IPublicSignalRow, type IReportDumpOptions, type IRiskActivePosition, type IRiskCheckArgs, type IRiskSchema, type IRiskSignalRow, type IRiskValidation, type IRiskValidationFn, type IRiskValidationPayload, type IScheduledSignalCancelRow, type IScheduledSignalRow, type ISignalDto, type ISignalRow, type ISizingCalculateParams, type ISizingCalculateParamsATR, type ISizingCalculateParamsFixedPercentage, type ISizingCalculateParamsKelly, type ISizingParams, type ISizingParamsATR, type ISizingParamsFixedPercentage, type ISizingParamsKelly, type ISizingSchema, type ISizingSchemaATR, type ISizingSchemaFixedPercentage, type ISizingSchemaKelly, type IStorageSignalRow, type IStorageUtils, type IStrategyPnL, type IStrategyResult, type IStrategySchema, type IStrategyTickResult, type IStrategyTickResultActive, type IStrategyTickResultCancelled, type IStrategyTickResultClosed, type IStrategyTickResultIdle, type IStrategyTickResultOpened, type IStrategyTickResultScheduled, type IStrategyTickResultWaiting, type ITrailingStopCommitRow, type ITrailingTakeCommitRow, type IWalkerResults, type IWalkerSchema, type IWalkerStrategyResult, type InfoErrorNotification, Live, type LiveStatisticsModel, Markdown, MarkdownFileBase, MarkdownFolderBase, type MarkdownName, MethodContextService, type MetricStats, Notification, NotificationBacktest, type NotificationData, NotificationLive, type NotificationModel, Partial$1 as Partial, type PartialData, type PartialEvent, type PartialLossAvailableNotification, type PartialLossCommit, type PartialLossCommitNotification, type PartialLossContract, type PartialProfitAvailableNotification, type PartialProfitCommit, type PartialProfitCommitNotification, type PartialProfitContract, type PartialStatisticsModel, Performance, type PerformanceContract, type PerformanceMetricType, type PerformanceStatisticsModel, PersistBase, PersistBreakevenAdapter, PersistCandleAdapter, PersistNotificationAdapter, PersistPartialAdapter, PersistRiskAdapter, PersistScheduleAdapter, PersistSignalAdapter, PersistStorageAdapter, PositionSize, type ProgressBacktestContract, type ProgressWalkerContract, Report, ReportBase, type ReportName, Risk, type RiskContract, type RiskData, type RiskEvent, type RiskRejectionNotification, type RiskStatisticsModel, Schedule, type ScheduleData, type SchedulePingContract, type ScheduleStatisticsModel, type ScheduledEvent, type SignalCancelledNotification, type SignalClosedNotification, type SignalData, type SignalInterval, type SignalOpenedNotification, type SignalScheduledNotification, Storage, StorageBacktest, type StorageData, StorageLive, Strategy, type StrategyActionType, type StrategyCancelReason, type StrategyCloseReason, type StrategyCommitContract, type StrategyEvent, type StrategyStatisticsModel, type TMarkdownBase, type TNotificationUtilsCtor, type TPersistBase, type TPersistBaseCtor, type TReportBase, type TStorageUtilsCtor, type TickEvent, type TrailingStopCommit, type TrailingStopCommitNotification, type TrailingTakeCommit, type TrailingTakeCommitNotification, type ValidationErrorNotification, Walker, type WalkerCompleteContract, type WalkerContract, type WalkerMetric, type SignalData$1 as WalkerSignalData, type WalkerStatisticsModel, addActionSchema, addExchangeSchema, addFrameSchema, addRiskSchema, addSizingSchema, addStrategySchema, addWalkerSchema, alignToInterval, checkCandles, commitActivateScheduled, commitAverageBuy, commitBreakeven, commitCancelScheduled, commitClosePending, commitPartialLoss, commitPartialProfit, commitTrailingStop, commitTrailingTake, dumpMessages, emitters, formatPrice, formatQuantity, get, getActionSchema, getAveragePrice, getBacktestTimeframe, getCandles, getColumns, getConfig, getContext, getDate, getDefaultColumns, getDefaultConfig, getExchangeSchema, getFrameSchema, getMode, getNextCandles, getOrderBook, getRawCandles, getRiskSchema, getSizingSchema, getStrategySchema, getSymbol, getWalkerSchema, hasTradeContext, backtest as lib, listExchangeSchema, listFrameSchema, listRiskSchema, listSizingSchema, listStrategySchema, listWalkerSchema, listenActivePing, listenActivePingOnce, listenBacktestProgress, listenBreakevenAvailable, listenBreakevenAvailableOnce, listenDoneBacktest, listenDoneBacktestOnce, listenDoneLive, listenDoneLiveOnce, listenDoneWalker, listenDoneWalkerOnce, listenError, listenExit, listenPartialLossAvailable, listenPartialLossAvailableOnce, listenPartialProfitAvailable, listenPartialProfitAvailableOnce, listenPerformance, listenRisk, listenRiskOnce, listenSchedulePing, listenSchedulePingOnce, listenSignal, listenSignalBacktest, listenSignalBacktestOnce, listenSignalLive, listenSignalLiveOnce, listenSignalOnce, listenStrategyCommit, listenStrategyCommitOnce, listenValidation, listenWalker, listenWalkerComplete, listenWalkerOnce, listenWalkerProgress, overrideActionSchema, overrideExchangeSchema, overrideFrameSchema, overrideRiskSchema, overrideSizingSchema, overrideStrategySchema, overrideWalkerSchema, parseArgs, roundTicks, set, setColumns, setConfig, setLogger, stopStrategy, validate, waitForCandle, warmCandles };
21455
+ export { ActionBase, type ActivateScheduledCommit, type ActivateScheduledCommitNotification, type ActivePingContract, type AverageBuyCommit, Backtest, type BacktestStatisticsModel, Breakeven, type BreakevenAvailableNotification, type BreakevenCommit, type BreakevenCommitNotification, type BreakevenContract, type BreakevenData, Cache, type CancelScheduledCommit, type CandleData, type CandleInterval, type ClosePendingCommit, type ColumnConfig, type ColumnModel, Constant, type CriticalErrorNotification, type DoneContract, type EntityId, Exchange, ExecutionContextService, type FrameInterval, type GlobalConfig, Heat, type HeatmapStatisticsModel, type IActionSchema, type IActivateScheduledCommitRow, type IBidData, type IBreakevenCommitRow, type ICandleData, type ICommitRow, type IExchangeSchema, type IFrameSchema, type IHeatmapRow, type ILog, type ILogEntry, type ILogger, type IMarkdownDumpOptions, type INotificationUtils, type IOrderBookData, type IPartialLossCommitRow, type IPartialProfitCommitRow, type IPersistBase, type IPositionSizeATRParams, type IPositionSizeFixedPercentageParams, type IPositionSizeKellyParams, type IPublicAction, type IPublicCandleData, type IPublicSignalRow, type IReportDumpOptions, type IRiskActivePosition, type IRiskCheckArgs, type IRiskSchema, type IRiskSignalRow, type IRiskValidation, type IRiskValidationFn, type IRiskValidationPayload, type IScheduledSignalCancelRow, type IScheduledSignalRow, type ISignalDto, type ISignalRow, type ISizingCalculateParams, type ISizingCalculateParamsATR, type ISizingCalculateParamsFixedPercentage, type ISizingCalculateParamsKelly, type ISizingParams, type ISizingParamsATR, type ISizingParamsFixedPercentage, type ISizingParamsKelly, type ISizingSchema, type ISizingSchemaATR, type ISizingSchemaFixedPercentage, type ISizingSchemaKelly, type IStorageSignalRow, type IStorageUtils, type IStrategyPnL, type IStrategyResult, type IStrategySchema, type IStrategyTickResult, type IStrategyTickResultActive, type IStrategyTickResultCancelled, type IStrategyTickResultClosed, type IStrategyTickResultIdle, type IStrategyTickResultOpened, type IStrategyTickResultScheduled, type IStrategyTickResultWaiting, type ITrailingStopCommitRow, type ITrailingTakeCommitRow, type IWalkerResults, type IWalkerSchema, type IWalkerStrategyResult, type InfoErrorNotification, Live, type LiveStatisticsModel, Log, type LogData, Markdown, MarkdownFileBase, MarkdownFolderBase, type MarkdownName, MethodContextService, type MetricStats, Notification, NotificationBacktest, type NotificationData, NotificationLive, type NotificationModel, Partial$1 as Partial, type PartialData, type PartialEvent, type PartialLossAvailableNotification, type PartialLossCommit, type PartialLossCommitNotification, type PartialLossContract, type PartialProfitAvailableNotification, type PartialProfitCommit, type PartialProfitCommitNotification, type PartialProfitContract, type PartialStatisticsModel, Performance, type PerformanceContract, type PerformanceMetricType, type PerformanceStatisticsModel, PersistBase, PersistBreakevenAdapter, PersistCandleAdapter, PersistLogAdapter, PersistNotificationAdapter, PersistPartialAdapter, PersistRiskAdapter, PersistScheduleAdapter, PersistSignalAdapter, PersistStorageAdapter, PositionSize, type ProgressBacktestContract, type ProgressWalkerContract, Report, ReportBase, type ReportName, Risk, type RiskContract, type RiskData, type RiskEvent, type RiskRejectionNotification, type RiskStatisticsModel, Schedule, type ScheduleData, type SchedulePingContract, type ScheduleStatisticsModel, type ScheduledEvent, type SignalCancelledNotification, type SignalClosedNotification, type SignalData, type SignalInterval, type SignalOpenedNotification, type SignalScheduledNotification, Storage, StorageBacktest, type StorageData, StorageLive, Strategy, type StrategyActionType, type StrategyCancelReason, type StrategyCloseReason, type StrategyCommitContract, type StrategyEvent, type StrategyStatisticsModel, type TLogCtor, type TMarkdownBase, type TNotificationUtilsCtor, type TPersistBase, type TPersistBaseCtor, type TReportBase, type TStorageUtilsCtor, type TickEvent, type TrailingStopCommit, type TrailingStopCommitNotification, type TrailingTakeCommit, type TrailingTakeCommitNotification, type ValidationErrorNotification, Walker, type WalkerCompleteContract, type WalkerContract, type WalkerMetric, type SignalData$1 as WalkerSignalData, type WalkerStatisticsModel, addActionSchema, addExchangeSchema, addFrameSchema, addRiskSchema, addSizingSchema, addStrategySchema, addWalkerSchema, alignToInterval, checkCandles, commitActivateScheduled, commitAverageBuy, commitBreakeven, commitCancelScheduled, commitClosePending, commitPartialLoss, commitPartialProfit, commitTrailingStop, commitTrailingTake, dumpMessages, emitters, formatPrice, formatQuantity, get, getActionSchema, getAveragePrice, getBacktestTimeframe, getCandles, getColumns, getConfig, getContext, getDate, getDefaultColumns, getDefaultConfig, getExchangeSchema, getFrameSchema, getMode, getNextCandles, getOrderBook, getRawCandles, getRiskSchema, getSizingSchema, getStrategySchema, getSymbol, getWalkerSchema, hasTradeContext, backtest as lib, listExchangeSchema, listFrameSchema, listRiskSchema, listSizingSchema, listStrategySchema, listWalkerSchema, listenActivePing, listenActivePingOnce, listenBacktestProgress, listenBreakevenAvailable, listenBreakevenAvailableOnce, listenDoneBacktest, listenDoneBacktestOnce, listenDoneLive, listenDoneLiveOnce, listenDoneWalker, listenDoneWalkerOnce, listenError, listenExit, listenPartialLossAvailable, listenPartialLossAvailableOnce, listenPartialProfitAvailable, listenPartialProfitAvailableOnce, listenPerformance, listenRisk, listenRiskOnce, listenSchedulePing, listenSchedulePingOnce, listenSignal, listenSignalBacktest, listenSignalBacktestOnce, listenSignalLive, listenSignalLiveOnce, listenSignalOnce, listenStrategyCommit, listenStrategyCommitOnce, listenValidation, listenWalker, listenWalkerComplete, listenWalkerOnce, listenWalkerProgress, overrideActionSchema, overrideExchangeSchema, overrideFrameSchema, overrideRiskSchema, overrideSizingSchema, overrideStrategySchema, overrideWalkerSchema, parseArgs, roundTicks, set, setColumns, setConfig, setLogger, stopStrategy, validate, waitForCandle, warmCandles };