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

drush deploy -vvv doesn't give enough details #5909

Closed
andrechun opened this issue Mar 14, 2024 · 1 comment · Fixed by #5948
Closed

drush deploy -vvv doesn't give enough details #5909

andrechun opened this issue Mar 14, 2024 · 1 comment · Fixed by #5948

Comments

@andrechun
Copy link

andrechun commented Mar 14, 2024

Describe the bug
When running drush deploy -vvv it doesn't output as much details as intended. It would only use --verbose argument to drush updatedb, drush config:import, drush cache:rebuild and drush deploy:hook. It should instead also use -vvv for those commands.

To Reproduce
Run: drush deploy -vvv

Expected behavior
In the debug output, it should show in each step that it is also using -vvv i.e. drush cache:rebuild -vvv and not --verbose

Actual behavior
It shows that it is executing each step with just --verbose

>  [info] Executing: /var/www/html/vendor/bin/drush updatedb:status --verbose --strict=0 --uri=https://xxx
>  [success] No pending updates.
 [success] Config import start. [18.83 sec, 45.87 MB]
 [info] Executing: /var/www/html/vendor/bin/drush config:import --verbose --uri=https://xxx [18.83 sec, 45.87 MB]

Workaround
Is there another way to do the desired action?

System Configuration

Q A
Drush version? 12.4.3
Drupal version? 10.1.8
PHP version 8.1
OS? Linux

Additional information
Add any other context about the problem here.

@weitzman
Copy link
Member

Sounds like a bug. The function responsible for gathering those options from the original request is \Drush\Drush::redispatchOptions

weitzman added a commit to consolidation/site-process that referenced this issue Mar 30, 2024
--verbose=3 is not allowed by its InputDefinition. --verbose does not accept a value (i.e. is VALUE_NONE). It must be passed as short option.

So we enable convertOptions() to pass along short options via a magic value `-short`. Magic values of true and false are already supported so hopefully this doesnt smell too bad.

This enables a fix for drush-ops/drush#5909
weitzman added a commit to weitzman/drush that referenced this issue Mar 30, 2024
greg-1-anderson pushed a commit to consolidation/site-process that referenced this issue Apr 1, 2024
* Allow short options. Needed to pass along -vvv

--verbose=3 is not allowed by its InputDefinition. --verbose does not accept a value (i.e. is VALUE_NONE). It must be passed as short option.

So we enable convertOptions() to pass along short options via a magic value `-short`. Magic values of true and false are already supported so hopefully this doesnt smell too bad.

This enables a fix for drush-ops/drush#5909

* Use constant

* Implement feedback

* Fix test
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

Successfully merging a pull request may close this issue.

2 participants