Skip to content

Metrics not flushed for generator functions #112

Closed
@acradu

Description

@acradu

Hello,
I recently discovered that the metrics I was emitting from some generator functions were not actually being emitted and after some digging I found that the reason is that @metric_scope doesn't actually iterate the generator, so logger.flush() occurs before any consumer attempts to use the generator.

Is this expected behavior or actually a bug?

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