question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Postal codes aren't returned anymore

See original GitHub issue

Do you want to request a feature or report a bug? Bug

What is the current behavior? The API used to return postal code information, however, since a couple of hours, it doesn’t anymore.

If the current behavior is a bug, please provide all the steps to reproduce and a minimal JSFiddle example or a repository on GitHub that we can npm install and npm start.

  • Type an address in the example page.
  • Look at the API output, the postal code isn’t returned anymore.

What is the expected behavior? Postal code should be returned, it’s a very important part of an address.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:7
  • Comments:11 (2 by maintainers)

github_iconTop GitHub Comments

11reactions
JonathanMontanecommented, Oct 30, 2019

Thanks everyone for the reports.

Issues with the data present in Places can arise in two locations:

  • data issue: It can be that the data is not present in OpenStreetMap and / or Geonames. These two projects are community based and there can be changes that makes some data disappear, or be incorrect.
  • processing issue: It can be a bug in our processing pipeline, which fails to extract the data present in OSM and Geonames.

I have investigated each address that was provided in this thread, and I will try to answer what might be causing the issue for each of them.

Calabasas, CA

Calabasas, CA does not have postcode data in OSM. Geonames does have data about Calabasas, CA but there was a change in its status last year (moved from PPL - populated place - to PPLX - section of populated place).

We do not rely on PPLX because there is too much outdated data in this type of records in Geonames, and the decomposition of PPLX is unclear with it sometimes being suburbs, general areas known by a name, etc. We do not plan on supporting PPLX type of data in our Geonames processing pipeline.

How to fix

  • This issue is a data issue and can be fixed by adding the postcode data in OpenStreetMap.

226 rue St-Joseph E

226 rue St-Joseph E does not have postcode data in OSM. Geonames dataset only covers cities and is not applicable to this situation. Based on the data available in the OSM snapshot, we could not derive a postcode for this street. This can happen if nearby features in OSM changed in notable ways. I checked the data processed for our next release and it seems that we should be able to derive a postcode for this street.

How to fix

  • This issue is a data issue but it has already been fixed by changes in recent versions of OSM. We will do a new release with the most up-to-date data that we have available, which should fix the issue.

Volgograd

Volgograd does not have postcode data in OSM, nor in Geonames

How to fix

  • This issue is a data issue and can be fixed by adding the postcode data in Geonames and/or OpenStreetMap. Updates from Geonames are faster to propagate to Places.

Ciudad de Mexico

Ciudad de Mexico is a very large city, and spans many postcodes areas. Because of that, the OSM format is not suited to hold postcode information, as OSM features can only have one addr:postcode attribute. Therefore the OSM data does not have postcode data. To compensate for that, we leverage Geonames in this situation as Geonames cities can have multiple postcodes. Unfortunately Geonames does not have postcode data for the city of Mexico.

How to fix

  • This issue is a data issue and can be fixed by adding the postcode data in Geonames.

Guadalajara

Guadalajara does not have postcode data in OSM, nor in Geonames. However, in this specific case, a recent update to the boundaries of the city in OpenStreetMap and the type of record used to define the city in OpenStreetMap make it so that we can have a computed postcode for this city in the next planet update that we do. Unfortunately, the change of boundaries happened after the OpenStreetMap data import that is currently reflected in Places, so the postcode could not be computed.

How to fix

  • This issue is data issue, but it has already been fixed by changes in recent versions of OSM. We will do a new release with the most up-to-date data that we have available, which should fix the issue.

We do not know why some postcodes disappeared from OSM in that specific snapshot, but we can confirm that some are back in the latest snapshot we have.

There can be many thousands of updates between different snapshots, with very subtle changes that can have large impacts, and we do not have the bandwidth to ensure that values stay consistent at the attribute level for every address on the planet between different snapshots, and we therefore rely on testing a reasonable number of addresses, which we can extend with new problematic addresses.

If you have any additional example of problematic addresses, don’t hesitate to share them with us in this thread.

9reactions
raphicommented, Nov 4, 2019

Hi everyone 👋

FYI following all of your comments, we decided to rollback to the previous data.

In the meantime, we will investigate why we lost some postcodes during the processing phase and will release a new version once fixed.

We are really sorry for the inconvenience, we will make sure to catch up such problems before update our data next time 🙏

Will keep you up when the next version is available.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to shop online if you don't have a postal code ... - Quora
If you dont have a postal code where you live, then go to the local/county EMA office and ask them for an address...
Read more >
507 Mailer Services | Postal Explorer
The service type code in the Intelligent Mail barcode will take precedence over ... Pieces endorsed “Change Service Requested” are not returned to...
Read more >
What's a credit card postal code? - WalletHub
A credit card postal code is the ZIP code associated with a credit card's ... Credit card postal codes aren't the most complex...
Read more >
Where's My Mail? | USPS Office of Inspector General
My zip code is 60803, our post office is the Mt. Greenwood post office, we have not had mail delivery since May 5th...
Read more >
No more 'return to sender?' Latin American countries move to ...
In many parts of Latin America, these are not just the directions you ... Efforts to name streets and introduce postal codes in...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found