fluxy-bot 0.5.10 → 0.5.11

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fluxy-bot",
3
- "version": "0.5.10",
3
+ "version": "0.5.11",
4
4
  "description": "Self-hosted, self-evolving AI agent with its own dashboard.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -228,12 +228,15 @@ function tick() {
228
228
 
229
229
  // ── Cron check ──
230
230
  const crons = readCronsConfig();
231
- const firedOneShots: string[] = [];
232
231
 
233
232
  for (const cron of crons) {
234
233
  if (!cron.enabled || !cron.id || !cron.schedule) continue;
235
234
 
236
- if (cronMatchesNow(cron.schedule)) {
235
+ const matches = cronMatchesNow(cron.schedule);
236
+ const nowDate = new Date();
237
+ log.info(`[scheduler] Cron "${cron.id}" schedule="${cron.schedule}" matches=${matches} now=${nowDate.getHours()}:${String(nowDate.getMinutes()).padStart(2,'0')}`);
238
+
239
+ if (matches) {
237
240
  const lastRun = lastCronRuns.get(cron.id) || 0;
238
241
  const oneMinuteAgo = now - 60_000;
239
242
  if (lastRun < oneMinuteAgo) {
@@ -253,6 +256,7 @@ function tick() {
253
256
  if (crons.length > 0) {
254
257
  const cleaned = crons.filter((c) => {
255
258
  if (c.oneShot && cronIsExpired(c.schedule)) {
259
+ log.info(`[scheduler] cronIsExpired=true for "${c.id}" schedule="${c.schedule}"`);
256
260
  log.info(`[scheduler] Removing expired one-shot cron: ${c.id}`);
257
261
  return false;
258
262
  }