This123
This123

Reputation: 71

Manually deleted package in External Libraries/Dart Packages not reappearring (Android Studio)

I manually deleted a package in External libraries/dart packages. Now I tried to run packages get again. The package(tesseract_ocr) did not appear in External libraries/dart packages. I tried removing it in pubspec.yaml and re-adding it but did not appear again. I tried deleting .pub-cache and run packages get again. I tried flutter clean, flutter pub cache repair, flutter pub cache add tessarect_ocr and packages get so many times but none of them made tessarect_ocr package reappear in External libraries/dart packages. Please Help. Thanks in advance!

Upvotes: 6

Views: 1511

Answers (3)

Khurram Iqbal
Khurram Iqbal

Reputation: 1

I went to C:\Users\kk\AppData\Local\Pub\Cache\hosted\pub.dev
and deleted the file of package which was not in the packages list.

note: C:\Users\kk, here in my case "kk" is written, in your case it will be name of your pc.

Then click on the "pub get" after putting package name in pubspec.yaml folder under dependencies. *Make sure that your internet is working.

Now, go and check the packages list, you will see the package installed there.

Upvotes: 0

syed amir ali shah
syed amir ali shah

Reputation: 1

facing the same issue I did the following things: 1.

flutter pub cache clean

which reinstalled all the packages 2. `

flutter pub get

` which update the dependencies and it works.

Upvotes: 0

Khamidjon Khamidov
Khamidjon Khamidov

Reputation: 8899

Try

dart pub cache clean

or

flutter pub cache clean

Upvotes: 9

Related Questions