Skip to content

Duplicate Class Conflict: GeckoView with React Native WebRTC #247

@thelonewolf123

Description

@thelonewolf123

Description: I'm attempting to use GeckoView in conjunction with react-native-webrtc, but I am encountering duplicate class issues with the WebRTC libraries. Below are the details of the conflicts:

Duplicate class org.webrtc.AddIceObserver found in:
- geckoview-106.0.20221102214123.aar -> jetified-geckoview-106.0.20221102214123-runtime (org.mozilla.geckoview:geckoview:106.0.20221102214123)
- webrtc-124.0.0.aar -> jetified-webrtc-124.0.0-runtime (org.jitsi:webrtc:124.0.0)

Duplicate class org.webrtc.AndroidVideoDecoder found in:
- geckoview-106.0.20221102214123.aar -> jetified-geckoview-106.0.20221102214123-runtime (org.mozilla.geckoview:geckoview:106.0.20221102214123)
- webrtc-124.0.0.aar -> jetified-webrtc-124.0.0-runtime (org.jitsi:webrtc:124.0.0)

Duplicate class org.webrtc.AndroidVideoDecoder$1 found in:
- geckoview-106.0.20221102214123.aar -> jetified-geckoview-106.0.20221102214123-runtime (org.mozilla.geckoview:geckoview:106.0.20221102214123)
- webrtc-124.0.0.aar -> jetified-webrtc-124.0.0-runtime (org.jitsi:webrtc:124.0.0)

Duplicate class org.webrtc.AndroidVideoDecoder$DecodedTextureMetadata found in:
- geckoview-106.0.20221102214123.aar -> jetified-geckoview-106.0.20221102214123-runtime (org.mozilla.geckoview:geckoview:106.0.20221102214123)
- webrtc-124.0.0.aar -> jetified-webrtc-124.0.0-runtime (org.jitsi:webrtc:124.0.0)

This seems to be a conflict between the WebRTC implementations used by GeckoView and Jitsi’s WebRTC library. I am seeking guidance on how to resolve this conflict.

Steps to Reproduce:

  1. Integrate GeckoView and React Native WebRTC into a project.
  2. Build the project.
  3. The build fails with the above duplicate class errors.

Expected Behavior: The build should succeed without class conflicts between GeckoView and the WebRTC libraries.

Environment:

  • GeckoView Version: 106.0.20221102214123
  • WebRTC Version: 124.0.0 (from org.jitsi:webrtc)
  • React Native

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions