GithubHelp home page GithubHelp logo

Comments (7)

tredman avatar tredman commented on May 5, 2024 1

This is fixed in 2.4.3.

from beeline-python.

tredman avatar tredman commented on May 5, 2024

Thanks for the report! I have a fix in the works now and it should be released later today as 2.4.2 after I get it reviewed.

We do run the code through pyflakes and it is usually good at finding things like this, but apparently it doesn't catch unused function arguments because it's sometimes valid to define function arguments that go unused (implementing an interface, for example). I also tried pylint but it also didn't catch it. (it did catch some other issues - yay! so we're going to integrate that into our CI/CD going forward). I did add/update some tests to ensure this behavior works in the future.

from beeline-python.

lavie avatar lavie commented on May 5, 2024

WRT linters, I do think it's better to turn off such a rule (unused argument) on a line-by-line basis than turn it off completely. It's very rare to intentionally have a function with unused args... (interfaces in python?)...
Anyway, thanks for the speedy response. I would add also that a multi-threaded example of tracing with beeline would be very helpful. Clearly you took the time to make sure it works properly in the face of MT with TLS, so an example of tracing with parallel sub-spans would really shine. I found it tricky to get it to work, having to pass the trace_id and parent span id manually across threads.

from beeline-python.

tredman avatar tredman commented on May 5, 2024

We do mention it here in our official docs: https://docs.honeycomb.io/beeline/python/#using-traces - see "Threading and Traces". We haven't received any feedback from anyone using it yet though. Are the docs there consistent with your experience? Would appreciate any feedback you have. I'm sure there are things we could do to make it a smoother experience.

This issue will close when I land #47 but if you reply here I'll keep an eye on it. Thanks!

from beeline-python.

lavie avatar lavie commented on May 5, 2024

Oh I guess I missed that. Will give it a try next week.
Really appreciate the quick fix.

from beeline-python.

lavie avatar lavie commented on May 5, 2024

@tredman would you agree that the context manager should return a reference to the tracer?

Otherwise we can't do:

with beeline.tracer("name") as trace:
   start_thread_and_pass_trace(trace)
...

from beeline-python.

tredman avatar tredman commented on May 5, 2024

Yes, good catch! I'll open a new issue, thanks.

from beeline-python.

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.