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

is_sampled is always False #24

Open
AlllenShen opened this issue Mar 21, 2019 · 0 comments
Open

is_sampled is always False #24

AlllenShen opened this issue Mar 21, 2019 · 0 comments

Comments

@AlllenShen
Copy link

AlllenShen commented Mar 21, 2019

The is_sampled logic there will make it always be False.
If the view function is the first span in a trace, X-B3-Sampled is not definded in headers so it is set as Fasle. And then all spans in the call chain will be False.

I use it in two defferent flask applications and no one send trace info to server. When I changed this line to is_sampled = str(headers.get('X-B3-Sampled') or '1') == '1', it worked.

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