Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[am list] [Rust] Detect autometricization when the attribute is hidden by cfg_attr #144

Open
gagbo opened this issue Sep 29, 2023 · 0 comments

Comments

@gagbo
Copy link
Member

gagbo commented Sep 29, 2023

I didn't test this, so I am pretty sure that currently am list will not detect the autometrics macro if it uses any kind of conditional compilation flag:

#[cfg_attr(feature = "extra-metrics", autometrics::autometrics(objective = super::API_SLO))]
fn api_route_handler(args: Args) -> ApiResult<()> {
    Ok(())
}

We should add a test for this case on Rust queries, and make sure that it's properly detected as well when listing "instrumented functions"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant