Update correlation logic for 2015 Gazetteer
authorJeremy Stanley <fungi@yuggoth.org>
Wed, 5 Oct 2016 00:49:32 +0000 (00:49 +0000)
committerJeremy Stanley <fungi@yuggoth.org>
Wed, 5 Oct 2016 00:49:32 +0000 (00:49 +0000)
Simple update to handle new filenames for the 2015 US Census Bureau
Gazetteer. Also update a comment which still had the old NWS station
list URL.

weather.py

index d00f7ff..7d07e91 100644 (file)
@@ -1198,14 +1198,14 @@ def correlate():
     import codecs, datetime, hashlib, os, re, sys, tarfile, time, zipfile
     if pyversion("3"): import configparser
     else: import ConfigParser as configparser
     import codecs, datetime, hashlib, os, re, sys, tarfile, time, zipfile
     if pyversion("3"): import configparser
     else: import ConfigParser as configparser
-    gcounties_an = "2014_Gaz_counties_national.zip"
-    gcounties_fn = "2014_Gaz_counties_national.txt"
-    gcousubs_an = "2014_Gaz_cousubs_national.zip"
-    gcousubs_fn = "2014_Gaz_cousubs_national.txt"
-    gplace_an = "2014_Gaz_place_national.zip"
-    gplace_fn = "2014_Gaz_place_national.txt"
-    gzcta_an = "2014_Gaz_zcta_national.zip"
-    gzcta_fn = "2014_Gaz_zcta_national.txt"
+    gcounties_an = "2015_Gaz_counties_national.zip"
+    gcounties_fn = "2015_Gaz_counties_national.txt"
+    gcousubs_an = "2015_Gaz_cousubs_national.zip"
+    gcousubs_fn = "2015_Gaz_cousubs_national.txt"
+    gplace_an = "2015_Gaz_place_national.zip"
+    gplace_fn = "2015_Gaz_place_national.txt"
+    gzcta_an = "2015_Gaz_zcta_national.zip"
+    gzcta_fn = "2015_Gaz_zcta_national.txt"
     for filename in os.listdir("."):
         if re.match("bp[0-9][0-9][a-z][a-z][0-9][0-9].dbx$", filename):
             cpfzcf_fn = filename
     for filename in os.listdir("."):
         if re.match("bp[0-9][0-9][a-z][a-z][0-9][0-9].dbx$", filename):
             cpfzcf_fn = filename
@@ -1228,7 +1228,7 @@ def correlate():
 %s
 # generated by %s on %s from these public domain sources:
 #
 %s
 # generated by %s on %s from these public domain sources:
 #
-# http://www.census.gov/geo/maps-data/data/gazetteer2014.html
+# http://www.census.gov/geo/maps-data/data/gazetteer2015.html
 # %s %s %s
 # %s %s %s
 # %s %s %s
 # %s %s %s
 # %s %s %s
 # %s %s %s
@@ -1237,7 +1237,7 @@ def correlate():
 # http://www.weather.gov/geodata/catalog/wsom/html/cntyzone.htm
 # %s %s %s
 #
 # http://www.weather.gov/geodata/catalog/wsom/html/cntyzone.htm
 # %s %s %s
 #
-# http://weather.noaa.gov/data/nsd_cccc.txt
+# http://tgftp.nws.noaa.gov/data/nsd_cccc.txt
 # %s %s %s
 #
 # http://tgftp.nws.noaa.gov/data/zonecatalog.curr.tar
 # %s %s %s
 #
 # http://tgftp.nws.noaa.gov/data/zonecatalog.curr.tar