codingsince1985
Repos
20
Followers
52
Following
2

Go library to access geocoding and reverse geocoding APIs

446
56

800 UVa Online Judge solutions in Go

120
25

Compute message digest for large files in Go

74
16

A RESTful caching micro-service in Go backed by Couchbase

58
6

A backup utility in Go that prevents bitrot

0
0

Server pushes to client via gRPC and Protocol Buffers

0
0

Events

upgrade to python 3.11 image size is 482MB

Created at 3 weeks ago
Created at 2 months ago
Created at 2 months ago
codingsince1985 create tag v1.2.5
Created at 2 months ago
Issue #1: added debug logger and logging responses from OSM

@aleksey-korolev, done.

Created at 2 months ago
codingsince1985 create tag v1.8.2
Created at 2 months ago
Issue #1: added debug logger and logging responses from OSM

lgtm, thanks a lot @aleksey-korolev!

Created at 2 months ago
pull request closed
Issue #1: added debug logger and logging responses from OSM

Added debug logger to log responses from mapping provider

Created at 2 months ago

Issue #1: added debug logger and logging responses from OSM (#75)

  • Issue #1: added debug logger and logging responses from OSM

  • Issue #1: combined two err log messages into single one

  • Issue #1: removed logging of response body with err log level since it is logged with debug level already

Co-authored-by: Aleksey Korolev aleksey.korolev@humans.net

Created at 2 months ago
pull request closed
Add NotFoundError

#57

Created at 2 months ago
Add NotFoundError

it's not very necessary as long as what the meaning of nil pointer is clear, as explained https://github.com/codingsince1985/geo-golang/issues/57#issuecomment-1239013948

Created at 2 months ago
Geocode should not return a nil location and a nil error

i get the point of getting (nil, nil) from a function that returns (*geo.Location, error). however as a convention, we always check if err is nil first. in this case, err is nil, which means there's no error, please go ahead to check the value of *geo.Location type. the pointer here is designed for a reason. if it's not a pointer, we may have to introduce an error to differentiate zero-ed location from got nothing. a nil pointer is enough for client to know what happened.

Created at 2 months ago
Geocode should not return a nil location and a nil error

I just checked the openstreetmap response parser, and when the returned longitude and latitude are empty, it returns nil for both location and error.

Returning nil as a valid value when there is no error is undesirable. It means that we have to check the return value, regardless of whether we have a return error or not.

Instead, it would probably be good to return a sentinel error, such as ErrNoCoordsFound.

Created at 2 months ago