Commit graph

5 commits

Author SHA1 Message Date
adam
5c9826bed6 py-country: updated to 19.8.18
19.8.18:
- Fix installation on systems that don't have UTF-8
  as default encoding.
- Remove superfluous print debugging output.

19.7.15:
- Update to iso-codes 4.3.
- Add support for ISO 639-5 (Language Families and Groups).
- Drop support for Python 2.
- Add `search_fuzzy()` function to the countries database. This allows
  for dealing with user searches that aren't really aware of ISO 3166 (so,
  like, actual human beings). A bit of character normalization and prioritizing
  matches between multiple criteria allows building somewhat reasonable
  suggestion/autocompletion lists.
  Caveat emptor: no attention has been paid to performance in this feature.
2019-11-28 06:24:29 +00:00
adam
b92bef17aa py-country: updated to 18.12.8
18.12.8:
WARNING: This release contains a subtle but important API change that may break integrations!
Looking at 13416 I realized that I made a terrible API design choice with respect to how the get function should behave in Python. Probably under the influence of either too little or too much whiskey I went and implemented get so that it raises a KeyError instead of doing the Pythonic thing and returning None and allowing to customize the default. There was a bit of back-and-forth around this code in previous releases (specifically touching edge cases to have the Subdivision API behave “reasonably”, although there doesn’t seem to be one right way there.)
Anyway, when preparing this release and reviewing 13416 and the other related issues and changes from the past I noticed my mistake an decide to fix it going forward.
So, from now on get will behave as expected in Python and yes, this means you will have to update your integration code carefully now checking for None returns instead of expecting KeyErrors. This is work, but I think it’s worthwhile to uphold this convention within the Python community.

* Switch API from “get + KeyError” to ” get + default=None”. This is a subtle API-breaking change. Please update carefully.
* Update to iso-codes 4.1.
2019-05-31 12:37:04 +00:00
adam
3e86616ce1 py-country: updated to 18.5.26
18.5.26:
Fix 13394: incorrect KeyError shadowing in Subdivisions.get()
Fix 13398: make lazy loading thread-safe.

18.5.20:
Update to iso-codes 3.79.
2018-07-05 11:39:10 +00:00
adam
2a11fae3ec py-country: updated to 18.2.23
18.2.23:
Update to iso-codes 3.78.
2018-02-27 13:08:03 +00:00
adam
c7af1249ea PkgSrc: Renamed geography/py-pycountry to geography/py-country
17.5.14:
Update to iso-codes 3.75, which fixes 13389 again. (bad parent codes for GB).
Switch from building on drone.io (discontinued service) to bitbucket’s Pipelines.
Update pytest dependencies to get rid of API warnings.

17.01.08:
Update to iso-codes 3.73, which fixes 13389 (bad parent codes for CZ).

17.01.02:
Return empty lists from the subdivision database if the country exists but does not have any subdivisions. Fixes 13374.
Some typo fixes. Thanks to @VictorMireyev.
Update to iso-codes-3.72.
2017-08-27 12:27:13 +00:00