Architecture-components-samples: Getting Error:Unexpected metadata type found. while running the project

Created on 9 Jan 2018  Â·  15Comments  Â·  Source: android/architecture-components-samples

I'm getting error while loading the Basic sample project.

Most helpful comment

the solution is very simple you dont have to uninstall android studio. the issue ussually happens because you gradles cannot load data in the metadata folder or you have multiple data folder in the gradle file.
follow the following steps
1.go to "C:\Users\pc\.gradle\caches\modules-2\"
2.delete any metadata folder availabe.
3.return to android studio and rebuild your project ensuring that you have internet connections
5.wait for the gradle to download some files and sync then
6.everything should wwork well after doing that

All 15 comments

Please elaborate. No one can't help you without a good description of your problem. What error are you getting?

Actually I have downloaded the sample and tried to run it but before
complet build it is giving me error
Sometimes that gradle version not found or sometimes unexpected metadata
type found

On 09-Jan-2018 4:16 PM, "Ernest Zamelczyk" notifications@github.com wrote:

Please elaborate. No one can't help you without a good description of your
problem. What error are you getting?

—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/googlesamples/android-architecture-components/issues/277#issuecomment-356248564,
or mute the thread
https://github.com/notifications/unsubscribe-auth/Ad6PHXlxk6aAQ3hmyDRRqE7o92hC_iysks5tI0OEgaJpZM4RXUmK
.

Here is the image in the attachment

On 11-Jan-2018 10:11 AM, "Snehal Gongle" gonglesnehal4@gmail.com wrote:

>

On 11-Jan-2018 10:10 AM, "Snehal Gongle" gonglesnehal4@gmail.com wrote:

Actually I have downloaded the sample and tried to run it but before
complet build it is giving me error
Sometimes that gradle version not found or sometimes unexpected metadata
type found

On 09-Jan-2018 4:16 PM, "Ernest Zamelczyk" notifications@github.com
wrote:

Please elaborate. No one can't help you without a good description of
your problem. What error are you getting?

—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/googlesamples/android-architecture-components/issues/277#issuecomment-356248564,
or mute the thread
https://github.com/notifications/unsubscribe-auth/Ad6PHXlxk6aAQ3hmyDRRqE7o92hC_iysks5tI0OEgaJpZM4RXUmK
.

I just downloaded a fresh copy from the repository and it works fine.

Here are the steps that you need to do:

  1. Make sure you have the latest version of Android Studio
  2. Download a fresh copy from the repository
  3. Open Android Studio
  4. In Android Studio click Open an existing Android Studio project
  5. Go into the folder with downloaded repository and navigate to BasicSample
  6. Click Open

You'll get a popup saying that you should update gradle but no matter what you choose the project should build and run without problems. Give it a while for indexing and try to run it. There shouldn't be any errors, but in case you get one, please copy the whole error message and paste it here.

These are the problems that I'm facing

I'm not too good with Android Im just a starter so please bare with me 😄

Thanks and Regards
Snehalgongle

On 11-Jan-2018 5:48 PM, "Ernest Zamelczyk" notifications@github.com wrote:

I just downloaded a fresh copy from the repository and it works fine.

Here are the steps that you need to do:

  1. Make sure you have the latest version of Android Studio
  2. Download a fresh copy from the repository
  3. Open Android Studio
  4. In Android Studio click Open an existing Android Studio project
  5. Go into the folder with downloaded repository and navigate to
    BasicSample
  6. Click Open

You'll get a popup saying that you should update gradle but no matter what
you choose the project should build and run without problems. Give it a
while for indexing and try to run it. There shouldn't be any errors, but in
case you get one, please copy the whole error message and paste it here.

—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/googlesamples/android-architecture-components/issues/277#issuecomment-356917871,
or mute the thread
https://github.com/notifications/unsubscribe-auth/Ad6PHa8FsiX25nTG5tnyuQ06ybr-kUvAks5tJfv2gaJpZM4RXUmK
.

What issues? You didn't provide me with any error messages.

same issue happens here too. This is what I gets.

"Could not resolve all dependencies for configuration ':app:debugAndroidTestRuntimeClasspath'.
Could not load module metadata from C:\Users\Digital.gradle\caches\modules-2\metadata-2.36\descriptors\com.android.support.test\runner\1.0.2\5ac5911800d0dfe0ba2d29f224b8c2fb\descriptor.bin
Unexpected metadata type found."

Hi guys I am having the same issue of
Unexpected metadata type found

BUT this is happening with ANY code. Even with the "Hello world" code in Android Studio first tutorial.

Did someone solve it please?

I have been stuck and cannot run any code :(

Many thanks.

M.

LordKelvin111

Hello Kelvin, I just fixed that error by deleting the gradle file completely located inside the "local disk: c ".
And uninstalled the android studio completely. Now it works fine.
image
untitled

the solution is very simple you dont have to uninstall android studio. the issue ussually happens because you gradles cannot load data in the metadata folder or you have multiple data folder in the gradle file.
follow the following steps
1.go to "C:\Users\pc\.gradle\caches\modules-2\"
2.delete any metadata folder availabe.
3.return to android studio and rebuild your project ensuring that you have internet connections
5.wait for the gradle to download some files and sync then
6.everything should wwork well after doing that

These are the problems that I'm facing I'm not too good with Android Im just a starter so please bare with me 😄 Thanks and Regards Snehalgongle
…
On 11-Jan-2018 5:48 PM, "Ernest Zamelczyk" @.*> wrote: I just downloaded a fresh copy from the repository and it works fine. Here are the steps that you need to do: 1. Make sure you have the latest version of Android Studio 2. Download a fresh copy from the repository 3. Open Android Studio 4. In Android Studio click Open an existing Android Studio project 5. Go into the folder with downloaded repository and navigate to BasicSample 6. Click Open You'll get a popup saying that you should update gradle but no matter what you choose the project should build and run without problems. Give it a while for indexing and try to run it. There shouldn't be any errors, but in case you get one, please copy the whole error message and paste it here. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub <#277 (comment)>, or mute the thread https://github.com/notifications/unsubscribe-auth/Ad6PHa8FsiX25nTG5tnyuQ06ybr-kUvAks5tJfv2gaJpZM4RXUmK .

the solution is very simple you dont have to uninstall android studio. the issue ussually happens because you gradles cannot load data in the metadata folder or you have multiple data folder in the gradle file.
follow the following steps
1.go to "C:\Users\pc.gradle\caches\modules-2\"
2.delete any metadata folder availabe.
3.return to android studio and rebuild your project ensuring that you have internet connections
5.wait for the gradle to download some files and sync then
6.everything should wwork well after doing that

ERROR: Could not load module metadata
what the solution for this error..?

delete the .gradle file. Connect to the internet. Sync gradle.. Thats it.

On Tue, Mar 5, 2019 at 9:16 PM Sunny notifications@github.com wrote:

ERROR: Could not load module metadata
what the solution for this error..?

—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/googlesamples/android-architecture-components/issues/277#issuecomment-469730412,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AdBBwfLtM5POP2srcfF9CCAj5m1Tf425ks5vTpFtgaJpZM4RXUmK
.

Seems to be working now.

Unexpected metadata type found in android studio. how to handle this error ?
Capture

Was this page helpful?
0 / 5 - 0 ratings