Comments (2)
hi
May I confirm with you about the step to setup?
- create a project ( the billing is enabled by default )
- create an API key in by
click Create credentials > API key.
- disable the billing for this project.
the error message will be shown as follow?
{
"error": {
"code": 404,
"message": "Requested entity was not found.",
"status": "NOT_FOUND"
}
}
my raw query ( please replace YOU_KEY field )
curl --request GET \
--url 'https://roads.googleapis.com/v1/nearestRoads?points=60.170880%2C24.942795%7C60.170879%2C24.942796%7C60.170877%2C24.942796&key=YOU_KEY'
my guess
I think it did throw an error, you can find err = json.NewDecoder(httpResp.Body).Decode(resp)
will return an error as the response with error cannot mapped to resp
which is a reference from response := &NearestRoadsResponse{}
func (c *Client) getJSON(ctx context.Context, config *apiConfig, apiReq apiRequest, resp interface{}) error {
requestMetrics := c.metricReporter.NewRequest(config.path)
httpResp, err := c.get(ctx, config, apiReq)
if err != nil {
requestMetrics.EndRequest(ctx, err, httpResp, "")
return err
}
defer httpResp.Body.Close()
err = json.NewDecoder(httpResp.Body).Decode(resp)
requestMetrics.EndRequest(ctx, err, httpResp, httpResp.Header.Get("x-goog-maps-metro-area"))
return err
}
from google-maps-services-go.
Thanks for the response. I agree that the underlying raw API call throws the error. I think the issue is that unlike the geocoding go call, the error does not get propagated up to the developer. There may very well be an internal error but to the developer using the gmaps golang library, it looks like a silent failure.
As for reproduction, billing was not enabled by default but I imagine having a project with billing explicitly disabled will reproduce the issue.
from google-maps-services-go.
Related Issues (20)
- metrics.Request receives an already drained *http.Response HOT 2
- Is there a way to set range for radius parameters? HOT 2
- googleMap Error: connect ECONNREFUSED 0.0.0.0:443 HOT 1
- maps.Client Automatic Retry? Exponential Backoff? HOT 1
- Static maps map_id parameter support HOT 2
- feat: add relative_time_description property to PlaceReview HOT 2
- Places Search has no json tag HOT 1
- ReverseGeocode: invalid character 'U' looking for beginning of value HOT 2
- Empty spaces in the README for the go get command HOT 2
- Client.PlaceDetails fails for ID ChIJUXcBoFD-nkcR3s74TnqlDHM HOT 5
- ParsePlaceSearchFieldMask missing case for 'business_status' HOT 2
- Address Validation API missing HOT 3
- Need extra "new line character" for few postalcodes to geolocate them HOT 1
- New APIs: Address Validation, Datasets, Fleet Engine, new Places API, Routes API
- Add support for Address Descriptors to Geocoding
- Tact is marked good
- Decorations, animation and logo HOT 3
- Provide response status code in case of error
- Images making and design creating I want to know how to create some stuff
- Add support for building and boundary calculations in geocoding response
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 google-maps-services-go.