Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle detailed postal codes for Great Britain #4

Open
rth opened this issue Nov 8, 2018 · 3 comments
Open

Handle detailed postal codes for Great Britain #4

rth opened this issue Nov 8, 2018 · 3 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@rth
Copy link
Member

rth commented Nov 8, 2018

The GB dataset for Great Britain only includes outwards codes (i.e. only first 3 letters). The full dataset is included in GB_full, but currently this fails to load,

>>> import pgeocode
>>> dist = pgeocode.GeoDistance('GB_full')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/rth/src/pgeocode/pgeocode.py", line 174, in __init__
    super(GeoDistance, self).__init__(country)
  File "/home/rth/src/pgeocode/pgeocode.py", line 49, in __init__
    .format(country))
ValueError: country=GB_FULL is not a known country code. See the README for a list of supported countries

Mostly making sure input validation works, in this case, should fix this, I think.

@rth rth added enhancement New feature or request good first issue Good for newcomers labels Nov 8, 2018
@amarchin
Copy link

Hi, I was looking for a package like pgeocode. Unfortunately I need the GB_full dataset so I open a PR to address this issue: #18

Let me know if you think it is acceptable :)

Thank you for the package!

@alvise1988
Copy link

Hello @rth ,

First of all, thanks for the useful package!

I would be looking exactly for this feature and most of the work seems to have been done already. Is there any particular reason why the PR was never merged?

Thanks

@martijnschouten
Copy link

martijnschouten commented Jan 4, 2021

I forked the package and edited it to support the full list of postal codes of the Netherlands and Great Brittain. See d32dace

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

4 participants