This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description

cid

Chinese Identity Parser

提取身份证号码中的生日、性别、办证区域, 校验身份证号码格式是否正确

Install

pip install cid

Usage

In [1]: from cid import IdParser

In [2]: ip = IdParser()

In [3]: ip.parse('360730198601011111')
Out[3]:
{'birthday': '1986-01-01',
 'gender': '男',
 'region': {'city': '赣州市', 'district': '宁都县', 'province': '江西省'}}

# 校验身份证号码格式是否正确

In [4]: ip.is_valid_cid('360730198601011111')
Out[4]: False


In [5]: ip.extract_gender('360730198601011111')
Out[5]: '男'

In [6]: ip.extract_birthday('360730198601011111')
Out[6]: '1986-01-01'

In [7]: ip.extract_region('360730198601011111')
Out[7]: {'city': '赣州市', 'district': '宁都县', 'province': '江西省'}

# 除了提取发证地,需要实例化 IdParser 外, 其他方法可直接使用

In [8]: from cid import (is_valid_cid, extract_gender, extract_birthday)

Changelog

0.1.1 - Apr 1, 2016

  • update data.csv

0.1 - Apr 1, 2016

  • first version
Release History

Release History

0.1.1

This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
cid-0.1.1.tar.gz (39.7 kB) Copy SHA256 Checksum SHA256 Source Apr 5, 2016

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting