Skip to content

bug: PlatformAuditService missing 'log_event' method #374

Closed

Description

@vybe

Summary

Proactive message audit logging fails with 'PlatformAuditService' object has no attribute 'log_event'. This is a non-blocking warning - the proactive message still sends, but audit trail is not recorded.

Component

Backend / Proactive Message Service / Audit

Priority

P3 (warning only, functionality works)

Error

WARNING: Failed to audit proactive message: 'PlatformAuditService' object has no attribute 'log_event'

Location

  • File: src/backend/services/proactive_message_service.py
  • Function/Class: PlatformAuditService

Root Cause

The proactive message service attempts to call audit_service.log_event() but this method doesn't exist on PlatformAuditService. Either the method was renamed, removed, or the wrong service is being used.

Reproduction Steps

  1. Agent sends a proactive message via Telegram
  2. Message sends successfully
  3. Warning logged about audit failure

Suggested Fix

  1. Check PlatformAuditService for the correct method name (might be log() or record_event())
  2. Update proactive_message_service.py to use the correct method
  3. Or add the missing log_event() method to PlatformAuditService

Environment

  • Trinity version: d961621

Related

  • src/backend/services/proactive_message_service.py
  • src/backend/services/platform_audit_service.py

Metadata

Metadata

Assignees

Labels

complexity-lowpriority-p3theme-securitytype-bug

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions