Comments (7)
Well, not sure about that.
from geocoder.
Ping @havvg, still needed?
from geocoder.
Would be appreciated, yes!
I currently worked around it by replacing the provider by a custom one, which is hack-ish imho.
This at least solved the current use-case, but you cannot alter the locale
of the provider :(
<?php
use Symfony\Component\DependencyInjection\ContainerInterface;
use Geocoder\HttpAdapter\HttpAdapterInterface;
use Geocoder\Provider\GoogleMapsProvider as BaseProvider;
class GoogleMapsProvider extends BaseProvider
{
public function __construct(ContainerInterface $container, HttpAdapterInterface $adapter, $locale = null)
{
if ($container->isScopeActive('request') && $container->has('request')) {
$locale = $container->get('request')->getLocale();
}
parent::__construct($adapter, $locale);
}
}
from geocoder.
@havvg wanna write a PR?
from geocoder.
Yeah, will do!
from geocoder.
I'm currently writing the patch, but the test suite is failing (without changes): https://travis-ci.org/havvg/Geocoder/jobs/3280917
Does it make sense to actually issue requests to the providers backends?
Imho it's not actually testing the unit under test and allows glitches just like the current one to appear, although nothing might actually be broken within the library.
from geocoder.
@havvg don't worry.
from geocoder.
Related Issues (20)
- Clean wrong tag/release created by @JaZo HOT 5
- Unable to install providers HOT 4
- Always get the address id HOT 3
- Arcgis Provider HOT 3
- Static Maps HOT 1
- [Nominatim] Neighbourhood field HOT 1
- [Google] Administrative level 1 is defined twice HOT 4
- Serialization of 'Closure' is not allowed HOT 7
- Store Address In Database HOT 10
- Equivalent to NoResult Exception when updating from older versions HOT 2
- sublocality allways null HOT 8
- Tag new release HOT 1
- Abandoned dependency php-http/message-factory
- Reverse Geocode failure - Here maps - Undefined index: LocationId HOT 2
- Error installing geocoder-php/nominatim-provider HOT 8
- Documentation to create custom providers
- Google invalid response HOT 4
- Issues with PHP 8.1 during installation HOT 2
- Take exception message from provider response in case of statusCode >= 400
- Tag new release HOT 2
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 geocoder.