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

Var Dumper server does not work #33457

Closed
lyrixx opened this issue Sep 4, 2019 · 2 comments

Comments

@lyrixx
Copy link
Member

commented Sep 4, 2019

Symfony version(s) affected: 4.3.last

Description

>…egoire/dev/labs/serverless/monolog(appli +) composer require symfony/var-dumper --dev
Restricting packages listed in "symfony/symfony" to "4.3.*"
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Restricting packages listed in "symfony/symfony" to "4.3.*"
Package operations: 1 install, 0 updates, 0 removals
  - Installing symfony/var-dumper (v4.3.4): Loading from cache
Writing lock file
Generating autoload files
ocramius/package-versions: Generating version class...
ocramius/package-versions: ...done generating version class
Executing script cache:clear [OK]
Executing script assets:install public [OK]

>…egoire/dev/labs/serverless/monolog(appli *+) rm -rf var/cache/*
>…egoire/dev/labs/serverless/monolog(appli *+) php bin/console server:dump

                                                                                                                                                                     
  Command "server:dump" is not defined.                                                                                                                              
                                                                                                                                                                     
  Did you mean one of these?                                                                                                                                         
      config:dump-reference                                                                                                                                          
      server:log                                                                                                                                                     
      server:run                                                                                                                                                     
      server:start                                                                                                                                                   
      server:status                                                                                                                                                  
      server:stop                                                                                                                                                    
                                                                                                                                                                     
  You may be looking for a command provided by the "VarDumper Component" which is currently not installed. Try running "composer require symfony/var-dumper --dev".  

It looks like something is wrong here :/

And I notice another error. I added

$_SERVER['VAR_DUMPER_FORMAT'] = 'cli';

In my Controller, and after that, the response was blank, nothing. Is is intended?

@stof

This comment has been minimized.

Copy link
Member

commented Sep 4, 2019

do you have the DebugBundle in your project ? If no, the command would not be registered in the container, as DebugBundle is the one doing the wiring of debug tools in the framework.

@lyrixx

This comment has been minimized.

Copy link
Member Author

commented Sep 5, 2019

How to reproduce:

# composer create-project symfony/skeleton foobar
# cd foobar/
# bin/console server:dump
                                                                                                                                                                     
  There are no commands defined in the "server" namespace.                                                                                                           
                                                                                                                                                                     
  You may be looking for a command provided by the "VarDumper Component" which is currently not installed. Try running "composer require symfony/var-dumper --dev".  
# composer require symfony/var-dumper --dev
# bin/console server:dump
                                                                                                                                                                     
  There are no commands defined in the "server" namespace.                                                                                                           
                                                                                                                                                                     
  You may be looking for a command provided by the "VarDumper Component" which is currently not installed. Try running "composer require symfony/var-dumper --dev".                                                    

PR on the way

fabpot added a commit that referenced this issue Sep 6, 2019
bug #33469 [FrameworkBundle] Fixed suggested package for missing serv…
…er:dump command (lyrixx)

This PR was merged into the 4.3 branch.

Discussion
----------

[FrameworkBundle] Fixed suggested package for missing server:dump command

| Q             | A
| ------------- | ---
| Branch?       | 4.3
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #33457
| License       | MIT
| Doc PR        | -

Commits
-------

4017477 [FrameworkBundle] Fixed suggested package for missing server:dump command

@fabpot fabpot closed this Sep 6, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants
You can’t perform that action at this time.