@teamvibe/poller 0.1.62 → 0.1.63

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.
@@ -32,14 +32,16 @@ export async function postMaintenanceReports(brainPath, channelId) {
32
32
  const content = await readFile(filePath, 'utf-8');
33
33
  const report = JSON.parse(content);
34
34
  if (!report.operationType) {
35
- logger.warn(`[MaintenanceReporter] Skipping ${file}: missing operationType`);
36
- emitError('maintenance', `Skipping report ${file}: missing operationType`, { severity: 'warn' });
35
+ logger.warn(`[MaintenanceReporter] Removing invalid report ${file}: missing operationType`);
36
+ emitError('maintenance', `Removing invalid report ${file}: missing operationType`, { severity: 'warn' });
37
+ await unlink(filePath).catch(() => { });
37
38
  continue;
38
39
  }
39
40
  const eventType = OPERATION_TO_EVENT_TYPE[report.operationType];
40
41
  if (!eventType) {
41
- logger.warn(`[MaintenanceReporter] Skipping ${file}: unknown operationType "${report.operationType}"`);
42
- emitError('maintenance', `Skipping report ${file}: unknown operationType "${report.operationType}"`, { severity: 'warn' });
42
+ logger.warn(`[MaintenanceReporter] Removing report ${file}: unknown operationType "${report.operationType}"`);
43
+ emitError('maintenance', `Removing report ${file}: unknown operationType "${report.operationType}"`, { severity: 'warn' });
44
+ await unlink(filePath).catch(() => { });
43
45
  continue;
44
46
  }
45
47
  const payload = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@teamvibe/poller",
3
- "version": "0.1.62",
3
+ "version": "0.1.63",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "bin": {