Fedora 17 Update: python-pygeoip-0.2.6-1.fc17

updates at fedoraproject.org updates at fedoraproject.org
Tue May 28 01:07:39 UTC 2013

Fedora Update Notification
2013-05-09 09:03:25

Name        : python-pygeoip
Product     : Fedora 17
Version     : 0.2.6
Release     : 1.fc17
URL         : http://pypi.python.org/pypi/pygeoip
Summary     : Pure Python GeoIP API
Description :
Pure Python GeoIP API based on MaxMind's C-based Python API
but the code itself is ported from the Pure PHP GeoIP API.

Create your GeoIP instance with appropriate access flag. `STANDARD` reads
data from disk when needed, `MEMORY_CACHE` loads database into memory on
instantiation and `MMAP_CACHE` loads database into memory using mmap.

    import pygeoip
    gi = pygeoip.GeoIP('/usr/share/geoip/GeoIP.dat', pygeoip.MEMORY_CACHE)

Country lookup

    >>> gi.country_code_by_name('google.com')
    >>> gi.country_code_by_addr('')
    >>> gi.country_name_by_addr('')
    'United States'

City lookup

    >>> gi = pygeoip.GeoIP('/usr/share/geoip/GeoLiteCity.dat')
    >>> gi.record_by_addr('')
        'city': 'Mountain View',
        'region_name': 'CA',
        'area_code': 650,
        'longitude': -122.0574,
        'country_code3': 'USA',
        'latitude': 37.419199999999989,
        'postal_code': '94043',
        'dma_code': 807,
        'country_code': 'US',
        'country_name': 'United States'
    >>> gi.time_zone_by_addr('')

For more information, check out the full API documentation at

Update Information:

Initial packaging.

  [ 1 ] Bug #910235 - Review Request: python-pygeoip - Pure Python GeoIP API

This update can be installed with the "yum" update program.  Use 
su -c 'yum update python-pygeoip' at the command line.
For more information, refer to "Managing Software with yum",
available at http://docs.fedoraproject.org/yum/.

All packages are signed with the Fedora Project GPG key.  More details on the
GPG keys used by the Fedora Project can be found at

More information about the package-announce mailing list