-
Notifications
You must be signed in to change notification settings - Fork 28.6k
shared.sh: line 268: bin/cache/dart-sdk/bin/dart: No such file or directory #166568
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
Comments
@ryanheise |
In my case, I wasn't using any Git hooks. |
What flutter version are you on ? See if this helps further. |
I already worked around the issue by deleting the cache directory so I can't test that workaround right now. But this also means I can now run flutter doctor:
|
It happened again, so this time I deleted the cache directory and removed the
I ran the same workaround again and then it first gave the original error:
And then later started giving the second error:
|
Keeping the issue open for team's tracking. |
We've changed the model so that |
There IS a workaround? If so, I would appreciate if you could let me know. I have tried the previous suggestion above, but reported that it did not work. If I tried the wrong workaround, what is the correct workaround? (I've been in the middle of publishing a just_audio release for 5 days, and have only partially published some parts of the release, which is an awkward situation. I can't complete the release because this issue is preventing me from using the |
Ah, sorry @ryanheise I missed your last comment. Can you confirm which version (or Git revision) of Flutter you're currently on? It sounds like your cache is getting corrupted somehow, but it's not clear exactly how/why. Can you confirm that |
Thanks, @bkonyi . I can confirm that The only workaround so far that partially worked was to delete the cache and reset the engine id, then get the Right now, the cache is in the freshly restored state, and I haven't touched it since. If you would like me to make the issue happen again in order to try something, I can probably do that (but it's getting late, so tomorrow morning). Or, I could also try a |
I'm glad that you're at least able to get back into a working state, even if it's temporary, by blowing away your cache. @matanlurey, is the change to no longer commit |
If I test beta, I couldn't actually use it to publish just_audio, since I need to ensure that it passes just_audio's tests on stable. I'm also not sure I'd be certain whether the issue is resolved because it seems it can strike at any time. It may help to know what triggers it, then I could specifically test that action before and after switching channels. |
It crashed when switching to beta, running from
|
That crash was probably because the last active beta version was quite old. I ignored the crash and ran |
Thanks for trying out the beta channel for us! It's good to know there hasn't been any issues so far. |
However, is there a workaround for |
I think the only workaround would be to patch the relevant change from beta onto your stable branch, but I'm not sure what's the relevant change. Maybe @matanlurey can help here? |
It's OK for now, I use this script to temporarily fix things each time it happens: #!/bin/bash
cd $FLUTTER_HOME/bin/cache
rmdir dart-sdk
mv dart-sdk.old dart-sdk
git reset --hard |
There is nothing I can imagine we're changing at this point for older releases. If you still see issues in the latest stable (3.32+) please file a new issue. Thanks! |
Steps to reproduce
flutter xyz...
(e.g.flutter analyze
)Basically, the flutter tool always fails with this error. How exactly did it get into this state? I'm not sure! I didn't do anything, I promise ;-)
I had it happen once before, and I also don't think I did anything specific to trigger it that time either. More info below.
Actual results
The error is in the title. But in addition to that error, the flutter installation was modified.
So, the engine version was mysteriously changed, not at my request. I would have expected this file to track git, but obviously it's fetching an engine version automatically from elsewhere.
I can fix the issue by deleting the cache directory, reverting the changes back to git, and then the flutter tool will refetch everything and work. For a few days, at least.
Logs
Logs
Flutter Doctor output
Doctor output
Same error again. It is not possible to run flutter doctor
flutter doctor
gives the same error, but I have the latest version of Flutter as of a few days ago.The text was updated successfully, but these errors were encountered: