Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Duplicate class go.Seq found in modules jetified-packageone-runtime (packageone.aar) and jetified-packagetwo-runtime (packagetwo.aar)

I am trying to use two different go packages in my android app project

I am using gomobile and each package is compiled with

gomobile bind --target=android

They are imported like this

implementation files("libs/packageone.aar")
implementation files("libs/packagetwo.aar")

and they work separateley, but they conflict when i try to run the app.

and I get the following error

Duplicate class go.Seq found in modules jetified-packageone-runtime (packageone.aar) and jetified-packagetwo-runtime (packagetwo.aar)
like image 447
mama Avatar asked Oct 20 '25 07:10

mama


1 Answers

I made an issue and got this response:

Unfortunately, that won't work.

The recommended workaround is to bind both packageone and packagetwo at once, and build one .aar.

https://github.com/golang/go/issues/56567

like image 151
mama Avatar answered Oct 21 '25 21:10

mama