Java &引用;“重复类…”;android依赖项解析错误

Java &引用;“重复类…”;android依赖项解析错误,java,android,build.gradle,Java,Android,Build.gradle,我在stack overflow和gradle网站上尝试了所有建议的解决方案,但没有一个对我有效。我可能已经访问了所有关于如何解决这个问题的链接。在我的build.gradle中,当我添加行:implementation'com.google.cloud:google cloud texttospeech:1.2.1'时,我会得到构建错误。以下是我的日志的一部分: Duplicate class com.google.type.TimeOfDayProto found in modules je

我在stack overflow和gradle网站上尝试了所有建议的解决方案,但没有一个对我有效。我可能已经访问了所有关于如何解决这个问题的链接。在我的build.gradle中,当我添加行:implementation'com.google.cloud:google cloud texttospeech:1.2.1'时,我会得到构建错误。以下是我的日志的一部分:

Duplicate class com.google.type.TimeOfDayProto found in modules jetified-proto-google-common-protos-1.18.1.jar (com.google.api.grpc:proto-google-common-protos:1.18.1) and jetified-protolite-well-known-types-17.1.0-runtime.jar (com.google.firebase:protolite-well-known-types:17.1.0)
Duplicate class com.google.type.TimeZone found in modules jetified-proto-google-common-protos-1.18.1.jar (com.google.api.grpc:proto-google-common-protos:1.18.1) and jetified-protolite-well-known-types-17.1.0-runtime.jar (com.google.firebase:protolite-well-known-types:17.1.0)
Duplicate class com.google.type.TimeZone$1 found in modules jetified-proto-google-common-protos-1.18.1.jar (com.google.api.grpc:proto-google-common-protos:1.18.1) and jetified-protolite-well-known-types-17.1.0-runtime.jar (com.google.firebase:protolite-well-known-types:17.1.0)
Duplicate class com.google.type.TimeZone$Builder found in modules jetified-proto-google-common-protos-1.18.1.jar (com.google.api.grpc:proto-google-common-protos:1.18.1) and jetified-protolite-well-known-types-17.1.0-runtime.jar (com.google.firebase:protolite-well-known-types:17.1.0)
Duplicate class com.google.type.TimeZoneOrBuilder found in modules jetified-proto-google-common-protos-1.18.1.jar (com.google.api.grpc:proto-google-common-protos:1.18.1) and jetified-protolite-well-known-types-17.1.0-runtime.jar (com.google.firebase:protolite-well-known-types:17.1.0)```