geocode_records 0.1.4 → 0.1.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: bb43330e498049979f259e4c84056e035773e6e5
4
- data.tar.gz: 4b95dcbde1816170fe530cff54c0b29ea9fac43c
3
+ metadata.gz: 9f9481740c101b666c731e1071a7d019b3e5f580
4
+ data.tar.gz: c2f36a4a3908b26fdfab3fcba6f07892a8193ae3
5
5
  SHA512:
6
- metadata.gz: ee3b4dda7267a126fccaeb20c98c461ffc3068ca23bd3fe27f48d2731584649e1325d5dc49b0cd10873db6db3cc2f01d63e4660af14727a98ffdce2165302f2e
7
- data.tar.gz: 615be6818087fa934bb348ab9caf468b9f8e7bffd3e4bbb2d730328d6657e54ec5e9c26b1123fecfb9a391b29897b659d48f8b44eddb7876fbe9d26c3565490e
6
+ metadata.gz: 7a3189caf4b574054a078989e2cc5b23ebd0773525eee869c7e2da1ac6ef7a6257a8104c3d5b857d952a7cd16f2315796210474f0e45c54a5e79d554730fc503
7
+ data.tar.gz: 7410d0746fbd76029a0cd573804abe6bd5a553e46c1a8d2a84415b3fb8090da7ca7bec25a3a8888b0edb248cdc99385b7bc60cf7c981e05de03d071df81edf48
data/CHANGELOG CHANGED
@@ -1,3 +1,9 @@
1
+ 0.1.5 / 2017-10-15
2
+
3
+ * Enhancements
4
+
5
+ * Don't die on house numbers greater than 2^32
6
+
1
7
  0.1.4 / 2017-07-11
2
8
 
3
9
  * Enhancements
@@ -3,6 +3,7 @@ require 'upsert'
3
3
 
4
4
  class GeocodeRecords
5
5
  class UpdateTableFromCsv
6
+ MAX_INT = 2**31 - 1
6
7
  attr_private :connection
7
8
  attr_private :table_name
8
9
  attr_private :csv_path
@@ -18,6 +19,7 @@ class GeocodeRecords
18
19
  row = row.to_hash
19
20
  if hn = row['house_number']
20
21
  row['house_number'] = hn.to_i
22
+ next if row['house_number'] > MAX_INT
21
23
  end
22
24
  if default_city = row.delete('default_city')
23
25
  row['city'] = default_city
@@ -1,3 +1,3 @@
1
1
  class GeocodeRecords
2
- VERSION = '0.1.4'
2
+ VERSION = '0.1.5'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: geocode_records
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 0.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Seamus Abshere
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-07-11 00:00:00.000000000 Z
11
+ date: 2017-10-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activerecord