Repository navigation
feat: add chinese_phone_number tag for Mainland-China mobile numbers - #100
Merged
Merged
Conversation
lutpul
force-pushed
the
feat/chinese-phone-number
branch
from
September 7, 2026 11:32
029a674 to
1de3a11
Compare
lutpul
force-pushed
the
feat/chinese-phone-number
branch
from
September 7, 2026 11:39
1de3a11 to
a73ebe7
Compare
geshtng
approved these changes
Sep 13, 2026
bxcodec
approved these changes
Sep 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds a new
chinese_phone_numbertag that generates Mainland-China mobilenumbers (11 digits, e.g.
13812345678).Why
The current
phone_number/e_164_phone_numbertags only produce Westernstyle numbers. Chinese data sets currently only cover names.
How
prefixes (China Mobile / Unicom / Telecom / Broadnet, incl. MVNO & IoT
segments), then append 8 random digits.
chinese_first_name-style tags:tag constant +
PriorityTags+defaultTag+mapperTagregistration,Phonerinterface method, standaloneChinesePhoneNumber()helper andunit tests (interface method, standalone call, and struct-tag end-to-end).
Tests
go test -race ./...passes; new tests validate against^1[3-9]\d{9}$and prefix membership.