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

Console commands are missing breadcrumbs and context with BreadcrumbHandler #763

Open
Dukecz opened this issue Sep 19, 2023 · 0 comments
Open

Comments

@Dukecz
Copy link

Dukecz commented Sep 19, 2023

How do you use Sentry?

Self-hosted / on-premises

SDK version

3.5.0

Steps to reproduce

I have prepared minimal symfony project with sentry integration: https://github.com/Dukecz/sentrysymfonycommand

  1. clone repository
  2. set ENV variable SENTRY_DSN
  3. run composer install
  4. run php bin/console app:test

Expected result

Sentry should contain all logged events (https://github.com/Dukecz/sentrysymfonycommand/blob/master/src/Command/TestCommand.php) in breadcrumbs with context as it does when they are logged outside command.

image

Actual result

Sentry contains no breadcrumbs generated within command scope.

image

If I commented out $this->hub->popScope() in \Sentry\SentryBundle\EventListener\ConsoleListener::handleConsoleTerminateEvent , breadcrumbs got into Sentry

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Waiting for: Product Owner
Development

No branches or pull requests

2 participants