0

In my project, I tried to add a library and again canceled it in the middle and from then I got an error like "Unsupported modules found issue" for that I tried building the project again and again but still, the issue isn't resolved and later I deleted the .idea folder in the project directory and restarted the project but still, the error isn't resolved. So again I imported the project the option (Import project from (Gradle, Eclipse) ) And now my complete project is corrupted java files are corrupted and I tried many times building my project but now use.

some java classes are changed to different text formats and I'm frightened about this now as today is my submission date for the project.

I'm sharing the GitHub link for the project please check It and help me with this issue.

https://github.com/codeREDinnovations/Allio-Home-Services

Current code format of build gradle

 <component name="libraryTable">
  <library name="Gradle: androidx.lifecycle:lifecycle-livedata-core:2.2.0@aar">
    <CLASSES>
      <root url="file://$USER_HOME$/.gradle/caches/transforms-2/files-2.1/c7b8f61938aaea0bed5cace846765882/lifecycle-livedata-core-2.2.0/AndroidManifest.xml" />
      <root url="jar://$USER_HOME$/.gradle/caches/transforms-2/files-2.1/c7b8f61938aaea0bed5cace846765882/lifecycle-livedata-core-2.2.0/jars/classes.jar!/" />
      <root url="file://$USER_HOME$/.gradle/caches/transforms-2/files-2.1/c7b8f61938aaea0bed5cace846765882/lifecycle-livedata-core-2.2.0/res" />
    </CLASSES>
    <JAVADOC />
    <SOURCES>
      <root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/androidx.lifecycle/lifecycle-livedata-core/2.2.0/6dcd7f31093b360c4a8bced748159e6fd237ba52/lifecycle-livedata-core-2.2.0-sou

earlier format

// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
    repositories {
        google()
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:4.0.1'
        classpath 'com.google.gms:google-services:4.3.3'
        classpath 'com.google.firebase:firebase-crashlytics-gradle:2.2.1'
        classpath "androidx.navigation:navigation-safe-args-gradle-plugin:2.3.0"

        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

allprojects {
    repositories {
        google()
        jcenter()
        mavenCentral()

        maven { url "https://jitpack.io" }
    }
}

task clean(type: Delete) {
    delete rootProject.buildDir
}
  • try to take a look in File > Project Structures, and search around in there is the faulty module to delete it – Biscuit Sep 16 '20 at 07:21
  • It is not showing any libraries that are added to project –  Sep 16 '20 at 07:25

1 Answers1

1

Your link is not working. Could it maybe be a private repo?

In any case, this has happened to me in the past using Android Studio. Try opening your files in another editor and see if your files are actually corrupted. When it happened to me I would only see them corrupted in AS. If they have been corrupted as files (and not only in AS) you should try to recreate the project from scratch - clone again or download anew.

For me, deleting all the .iml files as well as the .idea directory worked. Allow me to redirect you to the following user answer for more info: https://stackoverflow.com/a/45950059/4088135

You can also try deleting the system cache (C:\Users\user\ .AndroidStudioX\system\caches) and the gradle cache (C:\Users\user.gradle\caches) and reopening AS. Usually what I've noticed in these types of situations is that AS screwed up somehow.

Panos Gr
  • 667
  • 5
  • 13
  • Actually the files added to the GitHub are in proper format but in my project, they changed the format. –  Sep 16 '20 at 07:55
  • Please try the recommendations above and let me know if they work for you. If so, I'd appreciate you accepting the answer, hope this helps! – Panos Gr Sep 16 '20 at 10:16