Comments (14)
This is because you are including both places and places-compat. You must remove one of them.
from android-places-demos.
If you remove the first one: com.google.android.libraries.places:places:1.0.0 the project doesn't compile.
If you remove the second one: com.google.android.libraries.places:places-compat:1.0.0 the project can compile, but in runtime doesn't work,
Any idea to resolve??
@eriknyk , could you resolve it ?
from android-places-demos.
I have the same problem and removing one of them doesn't solve the problem.
I left the com.google.android.libraries.places:places:1.0.0 and the error is exactly the same.
What should I do?
@eriknyk
from android-places-demos.
i am having the same problem
Error: Program type already present: com.google.android.libraries.places.api.internal.impl.net.pablo.AutocompletePredictionResult$StructuredFormatting
what should i do?
from android-places-demos.
@kamilwyszynski @dharmeshrathore Can you provide a link to your gradle file?
from android-places-demos.
Same problem here
from android-places-demos.
@McKabue can you provide a link to your gradle file?
from android-places-demos.
I have the same issue, what was the solution?
from android-places-demos.
Same problem any solution found?
from android-places-demos.
It was a library issue. Google is confusing with their new Places SDK migration description.
But I fixed the issue doing the following:
In Gradle App dependencies
implementation 'com.google.android.libraries.places:places:1.1.0' // Remove
implementation 'com.google.android.libraries.places:places-compat:1.1.0' // Add
*** In activity
import com.google.android.libraries.places.api.net.PlacesClient; // Remove
import com.google.android.libraries.places.api.Places; // Remove
*** Remove all com.google.android.gms.location.places and replace with:
import com.google.android.libraries.places.compat.AutocompletePredictionBufferResponse; // New
import com.google.android.libraries.places.compat.AutocompletePrediction; //New
import com.google.android.libraries.places.compat.AutocompleteFilter; //New
import com.google.android.libraries.places.compat.GeoDataClient; //New
import com.google.android.libraries.places.compat.Place; //New
import com.google.android.libraries.places.compat.Places; //New
import com.google.android.libraries.places.compat.PlaceBufferResponse; //New
from android-places-demos.
thanks for the info @jwilly12!
from android-places-demos.
@kamilwyszynski nope, I have not luck to get com.google.android.libraries.places.compat working,
I spend about half day trying to get this working, and after that I decided to rewrite the implementation with using new api so get rid of places.compat, and rewrite the code took in my case half hour.
from android-places-demos.
Duplicate class com.google.android.libraries.places.api.internal.impl.net.pablo.AutocompletePredictionResult found in modules classes.jar (com.google.android.libraries.places:places-compat:1.1.0) and classes.jar (com.google.android.libraries.places:places:1.1.0)
It's impossible to solve this duplicity until a solution to this problem appears, I'll continue using 'com.google.android.gms: play-services-places: 16.1.0'
from android-places-demos.
Just comment this 'com.google.android.libraries.places:places:1.0.0' use only this 'com.google.android.libraries.places:places-compat:1.0.0' issue will resolved.
from android-places-demos.
Related Issues (20)
- Bug: all buttons in the sample of Kotlin&v3 cause a crash HOT 15
- Places: Bug: missing fields to request on place details
- Search suggestions are invalid HOT 2
- Session for autocomplete is not working HOT 3
- Autocomplete Address Form sample: soft keyboard covers map
- Autocomplete Address Form sample: Multiple AC intents can open HOT 1
- Autocomplete Addres Form sample: Support API 30 HOT 1
- Remove jcenter()
- jcenter migartion to maven HOT 1
- Leaked GCP API Keys - Places, Maps APIs HOT 1
- Playstore shows "Leaked GCP API Keys" error HOT 2
- Places: ProgrammaticPlacePredictions apiException: 9012 : INVALID_REQUEST HOT 6
- Support display cutouts in Overlay mode HOT 2
- Incorrect use of TypeFilter in setTypesFilter
- Closing the Overlay textfield HOT 3
- Failed to resolve: com.google.android.libraries.places:places:3.1.0 HOT 2
- Required File: .github/CODEOWNERS
- Dependabot couldn't find a build.gradle for this project
- Place Autocomplete for Compose HOT 1
- Dependabot couldn't find the branch devsite
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from android-places-demos.