Skip to content

AnnotatedHooksClassFilter swallowing exceptions using wrong RobotLog method #1478

Closed
@bubner

Description

@bubner

Hi,

The AnnotatedHooksClassFilter class is using RobotLog.e when it should be using RobotLog.ee in order to log an exception caused by one of the SDK app hooks (@OnCreate, @OnDestroy, @OnCreateEventLoop, @WebHandlerRegistrar, etc.)

https://github.com/OpenFTC/Extracted-RC/blob/ce0a67af28c966c7a166ae51765e115a853734fc/FtcCommon/src/main/java/org/firstinspires/ftc/ftccommon/internal/AnnotatedHooksClassFilter.java#L168-L169

Any exceptions thrown during one of these hooks that can be implemented in user code are swallowed and all Logcat reports is the tag, making debugging difficult as it is unclear which hook or method call caused an exception.

Image

This is a minor issue that doesn't concern most FTC programmers but does make post-mortem analysis difficult when paired with libraries that use these hooks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions