Skip to content

Commit

Permalink
Updated patterns to libphonenumber v8.13.44 (#121)
Browse files Browse the repository at this point in the history
  • Loading branch information
tolstislon authored Aug 26, 2024
1 parent 1b6eb85 commit 5f0c858
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 14 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install flake8 pep8-naming pytest black pytest-cov phonenumbers==8.13.43
python -m pip install flake8 pep8-naming pytest black pytest-cov phonenumbers==8.13.44
python -m pip install -e .
- name: Flake8
run: |
Expand Down
2 changes: 1 addition & 1 deletion Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ verify_ssl = true
black = "==24.8.0"
flake8 = "==7.1.1"
pep8-naming = "==0.14.1"
phonenumbers = "==8.13.43"
phonenumbers = "==8.13.44"
pytest = "==8.3.2"
pytest-cov = "==5.0.0"
requests = "==2.32.3"
Expand Down
28 changes: 16 additions & 12 deletions phone_gen/patterns.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# -*- coding: utf-8 -*-
"""
Auto-generated file 2024-08-09 14:02:37 UTC (v3)
Resource: https://github.com/google/libphonenumber v8.13.43
Auto-generated file 2024-08-26 07:38:33 UTC (v3)
Resource: https://github.com/google/libphonenumber v8.13.44
"""


PATTERNS = {
"info": "libphonenumber v8.13.43",
"info": "libphonenumber v8.13.44",
"data": {
"AC": {"code": "247", "pattern": "6[2-467]\\d{3}", "mobile": "4\\d{4}"},
"AD": {"code": "376", "pattern": "[78]\\d{5}", "mobile": "690\\d{6}|[356]\\d{5}"},
Expand Down Expand Up @@ -87,7 +87,7 @@
"BF": {
"code": "226",
"pattern": "2(?:0(?:49|5[23]|6[5-7]|9[016-9])|4(?:4[569]|5[4-6]|6[5-7]|7[0179])|5(?:[34]\\d|50|6[5-7]))\\d{4}",
"mobile": "(?:0[1-35-7]|5[0-8]|[67]\\d)\\d{6}",
"mobile": "(?:0[1-7]|5[0-8]|[67]\\d)\\d{6}",
},
"BG": {
"code": "359",
Expand Down Expand Up @@ -170,7 +170,11 @@
"pattern": "8(?:51(?:0(?:02|31|60|89)|1(?:18|76)|223)|91(?:0(?:1[0-2]|29)|1(?:[28]2|50|79)|2(?:10|64)|3(?:[06]8|22)|4[29]8|62\\d|70[23]|959))\\d{3}",
"mobile": "4(?:79[01]|83[0-389]|94[0-4])\\d{5}|4(?:[0-36]\\d|4[047-9]|5[0-25-9]|7[02-8]|8[0-24-9]|9[0-37-9])\\d{6}",
},
"CD": {"code": "243", "pattern": "12\\d{7}|[1-6]\\d{6}", "mobile": "88\\d{5}|(?:8[0-69]|9[017-9])\\d{7}"},
"CD": {
"code": "243",
"pattern": "(?:(?:12|573)\\d\\d|276)\\d{5}|[1-6]\\d{6}",
"mobile": "88\\d{5}|(?:8[0-69]|9[017-9])\\d{7}",
},
"CF": {"code": "236", "pattern": "2[12]\\d{6}", "mobile": "7[024-7]\\d{6}"},
"CG": {
"code": "242",
Expand Down Expand Up @@ -358,7 +362,7 @@
"GM": {
"code": "220",
"pattern": "(?:4(?:[23]\\d\\d|4(?:1[024679]|[6-9]\\d))|5(?:5(?:3\\d|4[0-7])|6[67]\\d|7(?:1[04]|2[035]|3[58]|48))|8\\d{3})\\d{3}",
"mobile": "(?:[23679]\\d|5[0-489])\\d{5}",
"mobile": "(?:[23679]\\d|4[015]|5[0-489])\\d{5}",
},
"GN": {
"code": "224",
Expand Down Expand Up @@ -694,7 +698,7 @@
"NF": {"code": "672", "pattern": "(?:1(?:06|17|28|39)|3[0-2]\\d)\\d{3}", "mobile": "(?:14|3[58])\\d{4}"},
"NG": {
"code": "234",
"pattern": "20(?:[1259]\\d|3[013-9]|4[1-8]|6[024-689]|7[1-79]|8[2-9])\\d{6}|(?:(?:[1-356]\\d|4[02-8]|8[2-9])\\d|9(?:0[3-9]|[1-9]\\d))\\d{5}|7(?:0(?:[013-689]\\d|2[0-24-9])\\d{3,4}|[1-79]\\d{6})|(?:[12]\\d|4[147]|5[14579]|6[1578]|7[1-3578])\\d{5}",
"pattern": "(?:20(?:[1259]\\d|3[013-9]|4[1-8]|6[024-689]|7[1-79]|8[2-9])|38)\\d{6}",
"mobile": "(?:702[0-24-9]|819[01])\\d{6}|(?:7(?:0[13-9]|[12]\\d)|8(?:0[1-9]|1[0-8])|9(?:0[1-9]|1[1-6]))\\d{7}",
},
"NI": {
Expand Down Expand Up @@ -795,7 +799,7 @@
"RO": {
"code": "40",
"pattern": "[23][13-6]\\d{7}|(?:2(?:19\\d|[3-6]\\d9)|31\\d\\d)\\d\\d",
"mobile": "(?:630|702)0\\d{5}|(?:6(?:[04]0|2\\d)|7(?:0[013-9]|1[0-3]|[2-7]\\d|8[03-8]|9[0-39]))\\d{6}",
"mobile": "(?:630|702)0\\d{5}|(?:6(?:00|2\\d)|7(?:0[013-9]|1[0-3]|[2-7]\\d|8[03-8]|9[0-39]))\\d{6}",
},
"RS": {
"code": "381",
Expand Down Expand Up @@ -828,7 +832,7 @@
"SG": {
"code": "65",
"pattern": "662[0-24-9]\\d{4}|6(?:[0-578]\\d|6[013-57-9]|9[0-35-9])\\d{5}",
"mobile": "8(?:09[0-68]|95[0-2])\\d{4}|(?:8(?:0[1-8]|[1-8]\\d|9[0-4])|9[0-8]\\d)\\d{5}",
"mobile": "8(?:09[0-689]|95[0-2])\\d{4}|(?:8(?:0[1-8]|[1-8]\\d|9[0-4])|9[0-8]\\d)\\d{5}",
},
"SH": {"code": "290", "pattern": "2(?:[0-57-9]\\d|6[4-9])\\d\\d", "mobile": "[56]\\d{4}"},
"SI": {
Expand All @@ -847,7 +851,7 @@
"SN": {
"code": "221",
"pattern": "3(?:0(?:1[0-2]|80)|282|3(?:8[1-9]|9[3-9])|611)\\d{5}",
"mobile": "7(?:(?:[06-8]\\d|21|90)\\d|5(?:01|[19]0|25|[38]3|[4-7]\\d))\\d{5}",
"mobile": "7(?:(?:[06-8]\\d|21|90)\\d|5(?:0[01]|[19]0|2[25]|[38]3|[4-7]\\d))\\d{5}",
},
"SO": {
"code": "252",
Expand Down Expand Up @@ -897,7 +901,7 @@
"TJ": {
"code": "992",
"pattern": "(?:3(?:1[3-5]|2[245]|3[12]|4[24-7]|5[25]|72)|4(?:46|74|87))\\d{6}",
"mobile": "(?:33[03-9]|4(?:1[18]|4[02-479])|81[1-9])\\d{6}|(?:0[0-57-9]|1[017]|2[02]|[34]0|5[05]|7[01578]|8[078]|9\\d)\\d{7}",
"mobile": "(?:33[03-9]|4(?:1[18]|4[02-479])|81[1-9])\\d{6}|(?:[09]\\d|1[017]|2[02]|[34]0|5[05]|7[01578]|8[078])\\d{7}",
},
"TK": {"code": "690", "pattern": "(?:2[2-4]|[34]\\d)\\d{2,5}", "mobile": "7[2-4]\\d{2,5}"},
"TL": {"code": "670", "pattern": "(?:2[1-5]|3[1-9]|4[1-4])\\d{5}", "mobile": "7[2-8]\\d{6}"},
Expand Down Expand Up @@ -950,7 +954,7 @@
},
"UY": {
"code": "598",
"pattern": "(?:1(?:770|9(?:20|87))|(?:2\\d|4[2-7])\\d\\d)\\d{4}",
"pattern": "(?:1(?:770|9(?:20|[89]7))|(?:2\\d|4[2-7])\\d\\d)\\d{4}",
"mobile": "9[1-9]\\d{6}",
},
"UZ": {
Expand Down

0 comments on commit 5f0c858

Please sign in to comment.