Code Monkey home page Code Monkey logo

Comments (9)

ryanheise avatar ryanheise commented on July 2, 2024 1

I've just made another fix attempt, although I haven't published it yet since it might be good to hear whether it works for you.

To try it out from Git master you can use this dependency in your pubspec.yaml:

  audio_session:
    git:
      url: https://github.com/ryanheise/audio_session.git

Note that if you use any other plugins that internally use audio_session, you'll also need to add a dependency override to force them to use this version of audio_session:

dependency_overrides:
  audio_session:
    git:
      url: https://github.com/ryanheise/audio_session.git

Let me know how it goes and if all is good I'll publish another release.

from audio_session.

ryanheise avatar ryanheise commented on July 2, 2024 1

FYI this has now been released in 0.1.5, thanks very much for reporting the issue.

from audio_session.

ryanheise avatar ryanheise commented on July 2, 2024

Do you have any error message that could help pinpoint the issue?

from audio_session.

ryanheise avatar ryanheise commented on July 2, 2024

I've done a sweep of the code and found a couple of APIs that were not guarded to the SDK level. The latest commit should fix that.

from audio_session.

musternet avatar musternet commented on July 2, 2024

I've done a sweep of the code and found a couple of APIs that were not guarded to the SDK level. The latest commit should fix that.

oh good then, the crash happened in the definition of the AudioSessionPlugin library in the android side anyway
flutterEngine.getPlugins().add(new com.ryanheise.audio_session.AudioSessionPlugin());
i think it might be because of what you mentioned. thanks

from audio_session.

ryanheise avatar ryanheise commented on July 2, 2024

I've just published release 0.1.4 with the above commit. Let me know how it goes, and if you still run into issues.

from audio_session.

musternet avatar musternet commented on July 2, 2024

I've just published release 0.1.4 with the above commit. Let me know how it goes, and if you still run into issues.

unfortunately it didn't work the AudioSessionPlugin can't be instantiated the error being shown in the log is this:

I/art: Rejecting re-init on previously-failed class java.lang.Class<com.ryanheise.audio_session.AndroidAudioManager$Singleton$1> I/art: Rejecting re-init on previously-failed class java.lang.Class<com.ryanheise.audio_session.AndroidAudioManager$Singleton$1> I/art: Rejecting re-init on previously-failed class java.lang.Class<com.ryanheise.audio_session.AndroidAudioManager$Singleton$1> W/GeneratedPluginsRegister: Tried to automatically register plugins with FlutterEngine (io.flutter.embedding.engine.FlutterEngine@2efb4784) but could not find and invoke the GeneratedPluginRegistrant. V/FA: Activity resumed, time: 1812723

N.B. its being thrown when defining singleton = new Singleton(applicationContext); in the AndroidAudioManager class

from audio_session.

ryanheise avatar ryanheise commented on July 2, 2024

Thanks, that gives me a good lead to go on.

from audio_session.

musternet avatar musternet commented on July 2, 2024

I'm using just_audio library that is dependant on audio_session library. I added the dependency override from the git master and everything is working fine now. i'll wait for the next release when all is done. thanks

from audio_session.

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.