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

Replace hardcoded name with Command::getName() in output message from UpdateCommand #10443

Merged
merged 1 commit into from
Jan 23, 2023

Conversation

phansys
Copy link
Contributor

@phansys phansys commented Jan 23, 2023

By instance, "doctrine/doctrine-bundle" defines the name doctrine:schema:update for this command, but the hardcoded value here generates a misleading message.

$ bin/console doctrine:schema:update --dump-sql

                                                                                                                        
 [WARNING] Not passing the "--complete" option to "orm:schema-tool:update" is deprecated and will not be supported when 
           using doctrine/dbal 4                                                                                        
                                                                                                                        

                                                                                                                        
 [OK] Nothing to update - your database is already in sync with the current entity metadata.                            

@phansys phansys marked this pull request as ready for review January 23, 2023 09:08
@greg0ire
Copy link
Member

Have you considered writing a test for this?

@phansys
Copy link
Contributor Author

phansys commented Jan 23, 2023

Have you considered writing a test for this?

No, but I think I can try.

@phansys phansys marked this pull request as draft January 23, 2023 10:03
@derrabus derrabus added the Bug label Jan 23, 2023
@derrabus
Copy link
Member

Good catch. Is this the only command where we've hardcoded the command name in some message?

@phansys
Copy link
Contributor Author

phansys commented Jan 23, 2023

Is this the only command where we've hardcoded the command name in some message?

I think so, I couldn't find other similar occurrences.

@phansys phansys force-pushed the update_command branch 2 times, most recently from 7b6285e to 6a33a2f Compare January 23, 2023 11:15
@phansys phansys marked this pull request as ready for review January 23, 2023 11:29
@derrabus derrabus merged commit eec3c42 into doctrine:2.14.x Jan 23, 2023
@phansys phansys deleted the update_command branch January 23, 2023 12:12
@greg0ire greg0ire added this to the 2.14.2 milestone Apr 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants