-
-
Notifications
You must be signed in to change notification settings - Fork 17
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
CommandFailedException #23
Comments
Thank you for reporting @marcvangend! |
(Un)fortunately (depending how you look at it 😉) I was not able to reproduce the problem. Here's how I tried to reproduce it:
|
Just had the same exception, just opening a non ddev project. This might be some type of race condition maybe... I will take a look at it. Thanks again for the infos! |
I got the error again, this time not when starting PhpStorm, but when waking my laptop from sleep mode. Maybe that tells you something. |
Just as a note:
|
Co-authored-by: Nico <nico.loeber94@gmail.com>
@marcvangend, could you please tell me which default shell you are using? I would guess its zsh with an enabled git plugin? |
Co-authored-by: Nico <nico.loeber94@gmail.com>
@nico-loeber pretty good guess! I use Fish with a git plugin. |
I was able to reproduce this issue. It's a timeout, since the ddev describe command took more than 5 seconds to load. If you are using a shell with some plugin that does some haeavy work, like collecting git information this may affect performance of all executed commands. We did some improvements to the error handling, so it is more obvious that a timeout is happening. We also increased the timeout from 5 to 8 seconds. Noramlly it should only take something around 100ms or less. I'm afraid I can't really offer you a solution right now. I would suggest not using such shell plugins. Could you maybe try to disable the git plugin, just to confirm this is causing the issue? |
As this issue is most probably caused by a 3rd party tool (shell with plugins) and we increased the timeout a bit, I will close this issue for now. |
Thanks for the debugging. Fish and its git prompt are essential for my day-to-day workflow, so I'm not going to disable either of them. Disabling fish temporarily is possible of course, but that only makes sense if I know a sure-fire way to reproduce the error. I don't know much about the internals of Fish and the git prompt, but I do know that the performance is pretty good. It never takes anything near 5 seconds to So anyway, suppose I just keep using Fish and the git prompt, and I run into this error once in a while... Would that be a bad thing? Does anything not work after this error occurs? If so, is there something I can do manually to restore the ddev plugin to a working state? |
Sadly I can't explain why the shell takes 5 seconds in to execute in this context. The error shouldn't be that a big problem. The plugin will restore its state after the next ddev action (start / stop / restart) or after 10 seconds. So you might experience some delay before you can use some features. We will keep an eye on this. I currently have no idea how to fix it and I don't see it critical for the 1.0 release, as this is "just" an issue with a 3rd party tool. Just decided to keep it open, as it is an open issue... |
Thank you, good to know that the plugin will restore itself to a working state. And please, there is no need to apologize! Open issues will always exist. The decision to spend your time on it, or ignore it, is all yours. I am entitled to nothing and very grateful that you are sharing your plugin with us. |
@marcvangend did you try if the alpah3 release does help to mitigate your issue? |
@nico-loeber I installed alpha-3 a couple of days ago. For what it's worth: I haven't seen the issue since. But then again, it didn't occur every day. |
The problem still occurs. There seems to be a bit more debug info on the first line now:
Also, I noticed there are two little arrows in the top left corner of the PhpStorm error dialog. I didn't notice those before, but it seems like this error has repeated more than 100 times since starting up this morning. After 100 errors, monitoring stopped. |
The error in #23 (comment) looks like docker isn't running, or The output is absolutely not the same or even related to the previous problem:
` |
Hmm, yeah, maybe the explanation really is that simple. I should try it out tomorrow. (Now I'm wondering why that didn't occur to me before. :-D) That said, it should be possible to run phpstorm without docker running, and not get any errors, right? |
Yes, we do already have an issue to avoid an exception when docker is not running: In case docker is not running at all the output of ddev describe seems to be I will try to reproduce this with the new information to implement a graceful handling of docker not running. Thank you both for your input, @marcvangend and @rfay! |
Stopping Docker while ddev is running causes: Will be hard to handle this as the exit status of ddev is always 1 and the message can vary. |
@marcvangend, do you have any update on this? |
Not really, I'm still getting the occasional error message. I do not always have time to dive in. Maybe it is worth mentioning that I do not auto-start Docker Desktop when I boot MacOS, so that might explain why I often have PhpStorm running before Docker and DDEV have started. But as a user of a plugin, I would expect the plugin to handle such a situation gracefully. |
Yes, this is an understandable request. Thanks for your feedback! |
Today, when starting PhpStorm, the IDE reported that this error occurred once:
This happened with a DDEV-enabled project, which had been opened with the DDEV-plugin before. At the moment I started PhpStorm, DDEV had already been started in a separate terminal.
I'm using the Alpha 2 release on PhpStorm build PS-221.5080.224 on MacOs.
The text was updated successfully, but these errors were encountered: