Skip to content
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

Failed to Resolve Dependency: android-issue-reporter Version 1.4.2 Not Found #161

Open
D4rK7355608 opened this issue Jan 11, 2024 · 6 comments

Comments

@D4rK7355608
Copy link
Contributor

Describe the bug

The latest version 1.4.2 of the android-issue-reporter library is not working as expected. The error message is: "Failed to resolve: com.heinrichreimersoftware:android-issue-reporter:1.4.2".

Reproduce

Steps to reproduce the behavior:

  1. Add the library with version 1.4.2.
  2. Try to build the project.
  3. See the error "Failed to resolve: com.heinrichreimersoftware:android-issue-reporter:1.4.2".

Expected behavior

The project should build successfully without any errors when using version 1.4.2 of the android-issue-reporter library.

Stack trace / screenshots

Unfortunately, I don't have a stack trace or screenshots at the moment.

Device

  • Device: [Not needed]
  • OS: [Not needed]
  • Browser: [Not needed]
  • Version: [Not needed]

Additional context

This issue started occurring after updating the library to version 1.4.2. The previous version 1.3.1 was working fine and is present on the Maven repository. However, version 1.4.2 is on JitPack, which could be causing the issue. It seems that the project is not able to resolve the dependency from JitPack, even after adding JitPack to the project's build files. A potential solution could be to provide an updated version of the dependency on both Maven and JitPack.

@D4rK7355608
Copy link
Contributor Author

After rewriting the settings.gradle.kt file with a better arrangement and a new syntax for the JitPack repo, that error disappeared. It’s no longer there.

It looks like it got the dependency. Here is the structure from the settings.gradle:

dependencyResolutionManagement {
    repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
    repositories {
        google()
        mavenCentral()
        maven {
            setUrl("https://jitpack.io")
        }
    }
}

But the repo doesn’t seem to be recognized due to some more issues related to unresolved classes and commands.

Here is a list of some errors:

  • Unresolved reference: IssueReporterLauncher and can’t be imported
  • Unresolved reference: IssueReporterActivity

I will take a closer look at the project and check what the problem is. Maybe it’s because of my project. But I will also take a look at the library on GitHub and contribute if I can.

@janheinrichmerker
Copy link
Owner

Here is the structure from the settings.gradle:

dependencyResolutionManagement {
    repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
    repositories {
        google()
        mavenCentral()
        maven {
            setUrl("https://jitpack.io")
        }
    }
}

Did the snippet from the readme (a simplified version of the above) not work?

dependencyResolutionManagement {
    repositories {
        maven(url = "https://jitpack.io")
    }
}

But the repo doesn’t seem to be recognized due to some more issues related to unresolved classes and commands.

Here is a list of some errors:

* Unresolved reference: IssueReporterLauncher and can’t be imported

* Unresolved reference: IssueReporterActivity

You probably need to import the classes com.heinrichreimersoftware.androidissuereporter.IssueReporterLauncher and/or com.heinrichreimersoftware.androidissuereporter.IssueReporterActivity. Normally, the IDE should suggest the import automatically. But we could add the explicit import to the readme.

@D4rK7355608
Copy link
Contributor Author

The explicit import doesn't have any influence and the classes don't seem to be recognized. The project has many issues.

The first reason I think the dependency has issues is related to the fact that it can't be fully implemented in the project. This is the reason why I actually can't import the classes even if I try to add them manually. This could be due to the fact that it isn't showing any error when it is imported with the:

       maven {
            setUrl("https://jitpack.io")
        }

But by adding the next code it can't find it:

dependencyResolutionManagement {
    repositories {
        maven(url = "https://jitpack.io")
    }
}

Another reason I think this is the case is because the project can be found in two places, on Maven and JitPack, and this could lead to a misinterpretation of this repo. As I said earlier, the version on Maven is 1.3.1 and on JitPack, it's 1.4.2.

The versions 1.4 and 1.4.1 cannot be imported as well because of the com.github.aakira:expandable-layout. One interesting thing is that on version 1.4 and 1.4.1 it wants to be added the dependecy com.github.aakira:expandable-layout manually because it can't find it. The version of com.github.aakira:expandable-layout is 1.5.0 and the latest one is 1.6.0. Even with this, the expandable layout dependency is very old and outdated, leading to some incompatibility issues. This leads me to think that the issues could be related to this, even if it isn't shown in the build log.

@simonpoole
Copy link

I just bumped the dependency to 1.4.2 on a project and it works just fine.

@simonpoole
Copy link

I just bumped the dependency to 1.4.2 on a project and it works just fine.

I would note that it doesn't actually work, my bad. Looking at jitpack the main issue seems to be that there is no actual aar file there, just the sources: https://jitpack.io/com/heinrichreimersoftware/android-issue-reporter/1.4.2/

@janheinrichmerker
Copy link
Owner

Unfortunately, I won't have time to fix this issue anytime soon. So the best you can do is to debug the JitPack build and then propose a pull request which I'd be more than happy to merge. Sorry for the inconvenience!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants