GithubHelp home page GithubHelp logo

assertion failed: meta.is_event() about console HOT 3 OPEN

dinhani avatar dinhani commented on June 25, 2024
assertion failed: meta.is_event()

from console.

Comments (3)

hds avatar hds commented on June 25, 2024

@dinhani Thanks for your issue report!

I would say that this is definitely incorrect on console-api side, even in debug mode we should be more resilient.

This will only happen if the console-subscriber is receiving traces that aren't from Tokio, since in the Tokio instrumentation we only use events and spans, but if we're going to have this assertion in place, we should be filtering out non-event/non-span callsites and not sending them on to the aggregator (we won't do anything with them anyway).

If you're interested in working on this, I propose that we check that the metadata received by register_callsite is either an event or a span, and otherwise we return Interest::never() and don't do any more:

fn register_callsite(&self, meta: &'static Metadata<'static>) -> subscriber::Interest {

We could add a test for this behaviour, although it looks like our test set-up doesn't fail the test when the subscriber thread panics, which is weird. I'll look at that separately.

from console.

dinhani avatar dinhani commented on June 25, 2024

I tested my project with the suggested change at register_callsite and it worked. There are no more panics.

I sent the suggested PR, but I still need to check how to test it properly in this project.

from console.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.