usa 0.1.0 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +11 -0
- data/README.md +6 -3
- data/db/seeds/counties.csv +18 -18
- data/db/seeds/states.csv +50 -50
- data/db/seeds/zips.csv +40818 -40818
- data/lib/usa/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 1138a018f777ee544ffaae4b4f0957bf583760a830bbb63f740143a1cff6552d
|
|
4
|
+
data.tar.gz: 3279df99a0c654797aea3803142650dad7ef2f94f1521eb6d7617c959ec38b7b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e072a57248277ea92c26cd41d1d85a99f5a36d7abcb2d6dee8f36f1796564ec012bb2ef37cbd7309f73fbcd2542bbdffa9686c3b6b27e97f3f1a713e37eaf071
|
|
7
|
+
data.tar.gz: a84c4a5ed0b32d98820b7df2521034a92a1da067753b82cf82b9a32b60366261d1841636919d1b761edf2d4c49071dba2961224c1ceee6da366b8ce76964b4a6
|
data/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,17 @@ For more information about changelogs, check [Keep a Changelog](http://keepachan
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## 0.2.0 - 2026-09-14
|
|
11
|
+
|
|
12
|
+
* [Feature] `google_place_id` filled for every state and ZIP, and for the twenty counties that
|
|
13
|
+
were blank: 50 of 51 states, 3,142 of 3,144 counties and 40,818 of 40,977 ZIPs, each the ID of
|
|
14
|
+
a place of the row's own kind, asked of the Geocoding API by component rather than by address
|
|
15
|
+
-- a state by its name and then its code, a county by its name and state, a ZIP by its code.
|
|
16
|
+
What stays blank is what Google has no such place for: the District of Columbia, Broomfield
|
|
17
|
+
County and Wrangell, which it keeps as cities, and 159 ZIPs it folds into a neighbor's. Cities
|
|
18
|
+
wait for a run of their own. `bin/geocode` is what fills a file, eight requests at a time,
|
|
19
|
+
taking only an answer of the right kind and logging the rest
|
|
20
|
+
|
|
10
21
|
## 0.1.0 - 2026-09-14
|
|
11
22
|
|
|
12
23
|
* [Feature] `USA::State`, `USA::County` and `USA::ZIP`, on `usa_states`, `usa_counties` and
|
data/README.md
CHANGED
|
@@ -12,7 +12,7 @@ To install on your system, run
|
|
|
12
12
|
|
|
13
13
|
To use inside a bundled Ruby project, add this line to the `Gemfile`:
|
|
14
14
|
|
|
15
|
-
gem 'usa', '~> 0.
|
|
15
|
+
gem 'usa', '~> 0.2.0'
|
|
16
16
|
|
|
17
17
|
Below 1.0 the pin stops at the next minor rather than the next major, because that is where a
|
|
18
18
|
breaking change may still land. It becomes `~> 1.0` once the API is settled on purpose.
|
|
@@ -58,8 +58,11 @@ A state has a `code`, a `fips` and a `name`. A county has a `fips`, a `name` and
|
|
|
58
58
|
has a `fips` -- a Census place code, unique within its state rather than nationally -- a `name`,
|
|
59
59
|
a state, and the one or more counties it lies in, since a city may cross a county line. A ZIP has
|
|
60
60
|
a `code`, the `city` it is addressed as, a `time_zone` named as Rails names one, and one county.
|
|
61
|
-
Every one of the four also has a `google_place_id`,
|
|
62
|
-
a
|
|
61
|
+
Every one of the four also has a `google_place_id`, the ID Google gives the place, which is what
|
|
62
|
+
draws a table of them as a map. It is filled for every state, county and ZIP that Google keeps
|
|
63
|
+
as an area of its kind, and blank for the few it keeps only as a city -- the District of
|
|
64
|
+
Columbia, Broomfield County, Wrangell -- for the ZIPs it folds into a neighbor's, and for every
|
|
65
|
+
city until a release fills them.
|
|
63
66
|
|
|
64
67
|
Two counter caches are kept by the seed rather than by a callback: `usa_states.counties_count`
|
|
65
68
|
and `usa_counties.zips_count`.
|
data/db/seeds/counties.csv
CHANGED
|
@@ -71,27 +71,27 @@ fips,name,state,google_place_id
|
|
|
71
71
|
02020,Anchorage Municipality,AK,ChIJQT-zBHaRyFYR42iEp1q6fSU
|
|
72
72
|
02050,Bethel Census Area,AK,ChIJAzKaLtLCIVcR4HXf_qNNZmk
|
|
73
73
|
02060,Bristol Bay Borough,AK,ChIJq3q39fef6FYRobLPUAsGQ0M
|
|
74
|
-
02063,Chugach Census Area,AK,
|
|
75
|
-
02066,Copper River Census Area,AK,
|
|
74
|
+
02063,Chugach Census Area,AK,ChIJj3x8PXcFt1YRvz112p0TjA8
|
|
75
|
+
02066,Copper River Census Area,AK,ChIJNRl_BvShtVYRDC6rbhNVxac
|
|
76
76
|
02068,Denali Borough,AK,ChIJOTWQqX-pzVYRqwYRa_-9avw
|
|
77
77
|
02070,Dillingham Census Area,AK,ChIJM-YORS8B3lYRZd4u0HiMW1g
|
|
78
78
|
02090,Fairbanks North Star Borough,AK,ChIJh1hyQyV_M1ERYrNgULUBLpA
|
|
79
79
|
02100,Haines Borough,AK,ChIJp6hr9o3pAVQRR7I8MzKIRgQ
|
|
80
|
-
02105,Hoonah-Angoon Census Area,AK,
|
|
80
|
+
02105,Hoonah-Angoon Census Area,AK,ChIJjY64IlEKAVQR07LV-Nz07zE
|
|
81
81
|
02110,Juneau City and Borough,AK,ChIJjzpqb2zeAFQREfNprlryXgY
|
|
82
82
|
02122,Kenai Peninsula Borough,AK,ChIJFfW41gNZwVYRamRfTxj0RdY
|
|
83
83
|
02130,Ketchikan Gateway Borough,AK,ChIJBc4nwh-fDlQRwEQtwhZU1CI
|
|
84
84
|
02150,Kodiak Island Borough,AK,ChIJ84Wen1SV61YR2LqkcZiadvc
|
|
85
|
-
02158,Kusilvak Census Area,AK,
|
|
85
|
+
02158,Kusilvak Census Area,AK,ChIJW4RSG5ZoJFcR2-oeYuGVuRQ
|
|
86
86
|
02164,Lake and Peninsula Borough,AK,ChIJI26TK2JC6FYR2uVT9p4NXxo
|
|
87
87
|
02170,Matanuska-Susitna Borough,AK,ChIJxT0fZPkfzFYReC4g704O-_c
|
|
88
88
|
02180,Nome Census Area,AK,ChIJ6ftI2sg4MVcRD6MakZY-GXk
|
|
89
89
|
02185,North Slope Borough,AK,ChIJB9NjWeWd2VARx-Cy8uG2nZc
|
|
90
90
|
02188,Northwest Arctic Borough,AK,ChIJM3vtHzeW01ARVYqgadp2wpI
|
|
91
|
-
02195,Petersburg Borough,AK,
|
|
92
|
-
02198,Prince of Wales-Hyder Census Area,AK,
|
|
91
|
+
02195,Petersburg Borough,AK,ChIJgy8SV5WrCFQRvJYQwir9fe4
|
|
92
|
+
02198,Prince of Wales-Hyder Census Area,AK,ChIJ4auid4_RDlQR-_YKUHqQ1ow
|
|
93
93
|
02220,Sitka City and Borough,AK,ChIJuWN1b4NmBFQRdBzIn0jaQSU
|
|
94
|
-
02230,Skagway Municipality,AK,
|
|
94
|
+
02230,Skagway Municipality,AK,ChIJfW5sY0WsqlYRfXwDxtKQkQs
|
|
95
95
|
02240,Southeast Fairbanks Census Area,AK,ChIJc2MxnobtNFERV6pifSHbErk
|
|
96
96
|
02275,Wrangell City and Borough,AK,
|
|
97
97
|
02282,Yakutat City and Borough,AK,ChIJAz4GIST0qVYRyXlvZrEutfo
|
|
@@ -308,15 +308,15 @@ fips,name,state,google_place_id
|
|
|
308
308
|
08121,Washington County,CO,ChIJwYuR4ZYUcocRubogihL3NfM
|
|
309
309
|
08123,Weld County,CO,ChIJCxObk9oHbIcR-vkuHPq7yHk
|
|
310
310
|
08125,Yuma County,CO,ChIJUZ28w7WYc4cRsoMbAMMbpPI
|
|
311
|
-
09110,Capitol Planning Region,CT,
|
|
312
|
-
09120,Greater Bridgeport Planning Region,CT,
|
|
313
|
-
09130,Lower Connecticut River Valley Planning Region,CT,
|
|
314
|
-
09140,Naugatuck Valley Planning Region,CT,
|
|
315
|
-
09150,Northeastern Connecticut Planning Region,CT,
|
|
316
|
-
09160,Northwest Hills Planning Region,CT,
|
|
317
|
-
09170,South Central Connecticut Planning Region,CT,
|
|
318
|
-
09180,Southeastern Connecticut Planning Region,CT,
|
|
319
|
-
09190,Western Connecticut Planning Region,CT,
|
|
311
|
+
09110,Capitol Planning Region,CT,ChIJl-MOLQBY5okR6480TjQjz4g
|
|
312
|
+
09120,Greater Bridgeport Planning Region,CT,ChIJmw39AgAM6IkR6Ht8FMVjupk
|
|
313
|
+
09130,Lower Connecticut River Valley Planning Region,CT,ChIJkd9vzko_5okRika6BRb2IdE
|
|
314
|
+
09140,Naugatuck Valley Planning Region,CT,ChIJWSHbHnbC54kR2OExZzZYylk
|
|
315
|
+
09150,Northeastern Connecticut Planning Region,CT,ChIJ0WI6CgB-5okRiQ0i_jB7hvQ
|
|
316
|
+
09160,Northwest Hills Planning Region,CT,ChIJTXQpLgCQ54kRsqipRm3_14Q
|
|
317
|
+
09170,South Central Connecticut Planning Region,CT,ChIJo9cWXl_X54kR3Fpv2_9vbKA
|
|
318
|
+
09180,Southeastern Connecticut Planning Region,CT,ChIJuUHEXlUN5okRq-4ChOdVbrI
|
|
319
|
+
09190,Western Connecticut Planning Region,CT,ChIJCQEpgQAC6IkRXEsiSRn1fXA
|
|
320
320
|
10001,Kent County,DE,ChIJ04r5Mk5hx4kRANs7LoMEe3U
|
|
321
321
|
10003,New Castle County,DE,ChIJh7_kg3Ybx4kR6L5mDoWESqw
|
|
322
322
|
10005,Sussex County,DE,ChIJaWUVnA-PuIkRzxJPFm9RUIg
|
|
@@ -363,7 +363,7 @@ fips,name,state,google_place_id
|
|
|
363
363
|
12081,Manatee County,FL,ChIJO3wisEEuw4gRJkeIhpCVu-Q
|
|
364
364
|
12083,Marion County,FL,ChIJaQaVRVXQ54gRCht5zsSwoNI
|
|
365
365
|
12085,Martin County,FL,ChIJ-V-yPH7H3ogRstggZi-Szls
|
|
366
|
-
12086,Miami-Dade County,FL,
|
|
366
|
+
12086,Miami-Dade County,FL,ChIJORjpTQWL2YgRi2OVgXQeaUk
|
|
367
367
|
12087,Monroe County,FL,ChIJmxojnNyG2ogRIGAhTf-Tm3I
|
|
368
368
|
12089,Nassau County,FL,ChIJqbrwpti85YgRwPnj3RzwMuE
|
|
369
369
|
12091,Okaloosa County,FL,ChIJ3dz0mGtskYgRHAGiUBwb5GI
|
|
@@ -2413,7 +2413,7 @@ fips,name,state,google_place_id
|
|
|
2413
2413
|
46097,Miner County,SD,ChIJET6yKJaPiIcR_-3Xqb8s5AI
|
|
2414
2414
|
46099,Minnehaha County,SD,ChIJ16y94Ji0jocRbXLuf-gRGrM
|
|
2415
2415
|
46101,Moody County,SD,ChIJyfcp4yFyiYcRip4nIKymrG0
|
|
2416
|
-
46102,Oglala Lakota County,SD,
|
|
2416
|
+
46102,Oglala Lakota County,SD,ChIJf7HEaFo8fIcRJ5KdPjGv22o
|
|
2417
2417
|
46103,Pennington County,SD,ChIJqR63oBhrfYcRKx7-WHYCfB8
|
|
2418
2418
|
46105,Perkins County,SD,ChIJQZh5Hx9WKVMRY9wjd9dF4Pc
|
|
2419
2419
|
46107,Potter County,SD,ChIJ2VErWScA1VIRlFg5X-OFRAw
|
data/db/seeds/states.csv
CHANGED
|
@@ -1,52 +1,52 @@
|
|
|
1
1
|
code,fips,name,google_place_id
|
|
2
|
-
AL,01,Alabama,
|
|
3
|
-
AK,02,Alaska,
|
|
4
|
-
AZ,04,Arizona,
|
|
5
|
-
AR,05,Arkansas,
|
|
6
|
-
CA,06,California,
|
|
7
|
-
CO,08,Colorado,
|
|
8
|
-
CT,09,Connecticut,
|
|
9
|
-
DE,10,Delaware,
|
|
2
|
+
AL,01,Alabama,ChIJdf5LHzR_hogR6czIUzU0VV4
|
|
3
|
+
AK,02,Alaska,ChIJG8CuwJzfAFQRNduKqSde27w
|
|
4
|
+
AZ,04,Arizona,ChIJaxhMy-sIK4cRcc3Bf7EnOUI
|
|
5
|
+
AR,05,Arkansas,ChIJYSc_dD-e0ocR0NLf_z5pBaQ
|
|
6
|
+
CA,06,California,ChIJPV4oX_65j4ARVW8IJ6IJUYs
|
|
7
|
+
CO,08,Colorado,ChIJt1YYm3QUQIcR_6eQSTGDVMc
|
|
8
|
+
CT,09,Connecticut,ChIJpVER8hFT5okR5XBhBVttmq4
|
|
9
|
+
DE,10,Delaware,ChIJO9YMTXYFx4kReOgEjBItHZQ
|
|
10
10
|
DC,11,District of Columbia,
|
|
11
|
-
FL,12,Florida,
|
|
12
|
-
GA,13,Georgia,
|
|
13
|
-
HI,15,Hawaii,
|
|
14
|
-
ID,16,Idaho,
|
|
15
|
-
IL,17,Illinois,
|
|
16
|
-
IN,18,Indiana,
|
|
17
|
-
IA,19,Iowa,
|
|
18
|
-
KS,20,Kansas,
|
|
19
|
-
KY,21,Kentucky,
|
|
20
|
-
LA,22,Louisiana,
|
|
21
|
-
ME,23,Maine,
|
|
22
|
-
MD,24,Maryland,
|
|
23
|
-
MA,25,Massachusetts,
|
|
24
|
-
MI,26,Michigan,
|
|
25
|
-
MN,27,Minnesota,
|
|
26
|
-
MS,28,Mississippi,
|
|
27
|
-
MO,29,Missouri,
|
|
28
|
-
MT,30,Montana,
|
|
29
|
-
NE,31,Nebraska,
|
|
30
|
-
NV,32,Nevada,
|
|
31
|
-
NH,33,New Hampshire,
|
|
32
|
-
NJ,34,New Jersey,
|
|
33
|
-
NM,35,New Mexico,
|
|
34
|
-
NY,36,New York,
|
|
35
|
-
NC,37,North Carolina,
|
|
36
|
-
ND,38,North Dakota,
|
|
37
|
-
OH,39,Ohio,
|
|
38
|
-
OK,40,Oklahoma,
|
|
39
|
-
OR,41,Oregon,
|
|
40
|
-
PA,42,Pennsylvania,
|
|
41
|
-
RI,44,Rhode Island,
|
|
42
|
-
SC,45,South Carolina,
|
|
43
|
-
SD,46,South Dakota,
|
|
44
|
-
TN,47,Tennessee,
|
|
45
|
-
TX,48,Texas,
|
|
46
|
-
UT,49,Utah,
|
|
47
|
-
VT,50,Vermont,
|
|
48
|
-
VA,51,Virginia,
|
|
49
|
-
WA,53,Washington,
|
|
50
|
-
WV,54,West Virginia,
|
|
51
|
-
WI,55,Wisconsin,
|
|
52
|
-
WY,56,Wyoming,
|
|
11
|
+
FL,12,Florida,ChIJvypWkWV2wYgR0E7HW9MTLvc
|
|
12
|
+
GA,13,Georgia,ChIJV4FfHcU28YgR5xBP7BC8hGY
|
|
13
|
+
HI,15,Hawaii,ChIJBeB5Twbb_3sRKIbMdNKCd0s
|
|
14
|
+
ID,16,Idaho,ChIJ6Znkhaj_WFMRWIf3FQUwa9A
|
|
15
|
+
IL,17,Illinois,ChIJGSZubzgtC4gRVlkRZFCCFX8
|
|
16
|
+
IN,18,Indiana,ChIJHRv42bxQa4gRcuwyy84vEH4
|
|
17
|
+
IA,19,Iowa,ChIJGWD48W9e7ocR2VnHV0pj78Y
|
|
18
|
+
KS,20,Kansas,ChIJawF8cXEXo4cRXwk-S6m0wmg
|
|
19
|
+
KY,21,Kentucky,ChIJyVMZi0xzQogR_N_MxU5vH3c
|
|
20
|
+
LA,22,Louisiana,ChIJZYIRslSkIIYRA0flgTL3Vck
|
|
21
|
+
ME,23,Maine,ChIJ1YpTHd4dsEwR0KggZ2_MedY
|
|
22
|
+
MD,24,Maryland,ChIJ35Dx6etNtokRsfZVdmU3r_I
|
|
23
|
+
MA,25,Massachusetts,ChIJ_b9z6W1l44kRHA2DVTbQxkU
|
|
24
|
+
MI,26,Michigan,ChIJEQTKxz2qTE0Rs8liellI3Zc
|
|
25
|
+
MN,27,Minnesota,ChIJmwt4YJpbWE0RD6L-EJvJogI
|
|
26
|
+
MS,28,Mississippi,ChIJGdRK5OQyKIYR2qbc6X8XDWI
|
|
27
|
+
MO,29,Missouri,ChIJfeMiSNXmwIcRcr1mBFnEW7U
|
|
28
|
+
MT,30,Montana,ChIJ04p7LZwrQVMRGGwqz1jWcfU
|
|
29
|
+
NE,31,Nebraska,ChIJ7fwMtciNk4cRxArzDwyQJ6E
|
|
30
|
+
NV,32,Nevada,ChIJcbTe-KEKmYARs5X8qooDR88
|
|
31
|
+
NH,33,New Hampshire,ChIJ66bAnUtEs0wR64CmJa8CyNc
|
|
32
|
+
NJ,34,New Jersey,ChIJn0AAnpX7wIkRjW0_-Ad70iw
|
|
33
|
+
NM,35,New Mexico,ChIJqVKY50NQGIcRup41Yxpuv0Y
|
|
34
|
+
NY,36,New York,ChIJqaUj8fBLzEwRZ5UY3sHGz90
|
|
35
|
+
NC,37,North Carolina,ChIJgRo4_MQfVIgRGa4i6fUwP60
|
|
36
|
+
ND,38,North Dakota,ChIJY-nYVxKD11IRyc9egzmahA0
|
|
37
|
+
OH,39,Ohio,ChIJwY5NtXrpNogRFtmfnDlkzeU
|
|
38
|
+
OK,40,Oklahoma,ChIJnU-ssRE5rIcRSOoKQDPPHF0
|
|
39
|
+
OR,41,Oregon,ChIJVWqfm3xuk1QRdrgLettlTH0
|
|
40
|
+
PA,42,Pennsylvania,ChIJieUyHiaALYgRPbQiUEchRsI
|
|
41
|
+
RI,44,Rhode Island,ChIJD9cOYhQ15IkR5wbB57wYTh4
|
|
42
|
+
SC,45,South Carolina,ChIJ49ExeWml-IgRnhcF9TKh_7k
|
|
43
|
+
SD,46,South Dakota,ChIJpTjphS1DfYcRt6SGMSnW8Ac
|
|
44
|
+
TN,47,Tennessee,ChIJA8-XniNLYYgRVpGBpcEgPgM
|
|
45
|
+
TX,48,Texas,ChIJSTKCCzZwQIYRPN4IGI8c6xY
|
|
46
|
+
UT,49,Utah,ChIJzfkTj8drTIcRP0bXbKVK370
|
|
47
|
+
VT,50,Vermont,ChIJ_87aSGzctEwRtGtUNnSJTSY
|
|
48
|
+
VA,51,Virginia,ChIJzbK8vXDWTIgRlaZGt0lBTsA
|
|
49
|
+
WA,53,Washington,ChIJ-bDD5__lhVQRuvNfbGh4QpQ
|
|
50
|
+
WV,54,West Virginia,ChIJRQnL1KVUSogRQzrN3mjHALs
|
|
51
|
+
WI,55,Wisconsin,ChIJr-OEkw_0qFIR1kmG-LjV1fI
|
|
52
|
+
WY,56,Wyoming,ChIJaS7hSDTiXocRLzh90nkisCY
|