Giter VIP home page Giter VIP logo

Comments (7)

monowar1993 avatar monowar1993 commented on September 22, 2024 2

Another work around is,
in your project's build.gradle file add

dependencies {
        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
        ...
        //TODO: Fix for new jetifier issue. Not be needed in gradle version 3.2.2
        classpath 'com.android.tools.build.jetifier:jetifier-processor:1.0.0-beta02'
    }

and in app build.gradle file add

dependencies {
     ...
     //TODO: Fix for new jetifier issue. Not be needed in gradle version 3.2.2
     kapt 'com.android.tools.build.jetifier:jetifier-core:1.0.0-beta02'
     annotationProcessor 'com.android.tools.build.jetifier:jetifier-core:1.0.0-beta02'
  }

from dart.

zsavely avatar zsavely commented on September 22, 2024

Part of the solution I came to was to exclude some package called com.google.android:android:

implementation("com.f2prateek.dart:dart:3.0.3") {
  exclude group: "com.google.android", module: "android"
}
implementation("com.f2prateek.dart:dart-annotations:3.0.3") {
  exclude group: "com.google.android", module: "android"
}
annotationProcessor("com.f2prateek.dart:dart-processor:3.0.3") {
  exclude group: "com.google.android", module: "android"
}

from dart.

stephanenicolas avatar stephanenicolas commented on September 22, 2024

from dart.

zsavely avatar zsavely commented on September 22, 2024

Hey @stephanenicolas,
If it was that simple, I won't be here and I really won't be bothering to write a workaround for a non-existent issue.
In my particular case, dart was the only one who used this dependency (do not really know what actually it serves for) and this particular library could not be 'jetified', so I just excluded it from dart. Seems to be working perfectly.
It might have been an issue with annotation processing not being jetified, but it's just a guess.

from dart.

stephanenicolas avatar stephanenicolas commented on September 22, 2024

from dart.

aoben10 avatar aoben10 commented on September 22, 2024

I'm using androidx, and I'm also running into an issue when trying to call Dart.inject(this) within my basefragment class. I keep getting the error

None of the following functions can be called with the arguments supplied:
public open fun inject(p0: Activity!): Unit defined in com.f2prateek.dart.Dart
public open fun inject(p0: Fragment!): Unit defined in com.f2prateek.dart.Dart

With androidx the fragment is in package androidx.fragment.app.Fragment instead of android.app.Fragment which I think might be causing the issue. I also have jetifier enabled android.enableJetifier=true. Using henson|dart version 2.0.3

Does anyone know how I resolve this issue?

from dart.

stephanenicolas avatar stephanenicolas commented on September 22, 2024

DH 3.1.1 is gonna be released and it will make it possible to use DH 3 with android X projects.
We don't have any plan for making things better for DH 2.

from dart.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.