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

Loses communication with worker when using dump() #868

Closed
carestad opened this issue Apr 15, 2024 · 5 comments
Closed

Loses communication with worker when using dump() #868

carestad opened this issue Apr 15, 2024 · 5 comments

Comments

@carestad
Copy link

carestad commented Apr 15, 2024

Octane Version

2.3.7

Laravel Version

11.3.1

PHP Version

8.3.6

What server type are you using?

Roadrunner

Server Version

2024.1.0

Database Driver & Version

sqlite

Description

I noticed when trying to debug a URL issue, that if you add a dump() (dd() works though) statement inside a closure based route definition (see here), the Roadrunner server will print an error (RoadRunner can't communicate with the worker) and the request gets a 500 response instead. No more info to trace anywhere as far as I can tell.

This might be intentional or by design, but would be nice to have documented if it is.

Steps To Reproduce

Repro repo: https://github.com/carestad/octane-dump-bug

Steps:

  1. git clone https://github.com/carestad/octane-dump-bug
  2. composer install
  3. php artisan octane:start --server roadrunner
  4. open http://localhost:8000/foo
Copy link

Thank you for reporting this issue!

As Laravel is an open source project, we rely on the community to help us diagnose and fix issues as it is not possible to research and fix every issue reported to us via GitHub.

If possible, please make a pull request fixing the issue you have described, along with corresponding tests. All pull requests are promptly reviewed by the Laravel team.

Thank you!

@AlliBalliBaba
Copy link
Contributor

This might be related to 838. dump() just doesn't output anything in Octane. You can try setting $_SERVER['VAR_DUMPER_FORMAT'] = 'html'; before dump() and see if it helps.

@sy-records
Copy link
Contributor

Duplicate of #856

@driesvints
Copy link
Member

thanks all. Looks like we're not taking any action here, sorry.

@whendryo-wytech
Copy link

whendryo-wytech commented Sep 6, 2024

An alternative is to include VAR_DUMPER_FORMAT=html in the .env

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

No branches or pull requests

5 participants