datanorm 1.0.6 → 1.0.7

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 94780a135bc40c972dddf9d72aee476440c10c3ac158bcc91dea68e28049014d
4
- data.tar.gz: f5ead4a1a2a6ae5c3996e1d5d41fb4a93ee80baca203a616edb4a1dcbbd01b8b
3
+ metadata.gz: 065ea784071baba768257ab08781410cf92791d66c67671868a461266bc97982
4
+ data.tar.gz: cac6e4d71a506b11c57dc6495b8c7bf03fa626d528915dac0f53bbbd9f03185a
5
5
  SHA512:
6
- metadata.gz: e0d4d7d2bf8f82378e9b524b3c59f37365fcaff69ad5e43dc6caa8942118bf8a5cec4cf763b0174755c2e6e803178118d04535d752880fbda3fcf247a1872870
7
- data.tar.gz: f5c97c506cba0110606b5a447f699f7250730d421d903faa78e3b516e20249712b24250a8ddd5507adea86eeaa524d0c5559d6a6b424e2eedee11a49270309bf
6
+ metadata.gz: 1a192ff308125a6259f38d1b649dc0166546b2da4ab028e4a12055051ae94ae085b446f412962bd366e7b42a75b248c66573973146a0171dba32c15851e990cf
7
+ data.tar.gz: 98075448fb648b86977353d9595f1ae6dcc3cfaa2aefd5719ac5a0daab90f6af17e0f129afe7bd582b84e70e8b27f56e74801ad4b8ec575453ab840753d8f970
@@ -13,7 +13,7 @@ module Datanorm
13
13
  def call
14
14
  return unless products_file.file?
15
15
 
16
- ::File.foreach(products_file) do |json|
16
+ ::File.foreach(products_file, encoding: Encoding::UTF_8) do |json|
17
17
  progress.increment!
18
18
 
19
19
  if yield_progress
@@ -34,7 +34,7 @@ module Datanorm
34
34
  return @products_count if defined?(@products_count)
35
35
 
36
36
  @products_count = 0
37
- ::File.foreach(products_file) { @products_count += 1 }
37
+ ::File.foreach(products_file, encoding: Encoding::UTF_8) { @products_count += 1 }
38
38
  @products_count
39
39
  end
40
40
 
@@ -153,7 +153,7 @@ module Datanorm
153
153
 
154
154
  @dimension_content = begin
155
155
  path = workdir.join('D', ::Datanorm::Helpers::Filename.call(id))
156
- path.read if path.file?
156
+ path.read(encoding: Encoding::UTF_8) if path.file?
157
157
  end
158
158
  end
159
159
 
@@ -31,14 +31,14 @@ module Datanorm
31
31
 
32
32
  def read_file!
33
33
  if split_newlines
34
- path.read.split("\n")
34
+ path.read(encoding: Encoding::UTF_8).split("\n")
35
35
  else
36
- path.read
36
+ path.read(encoding: Encoding::UTF_8)
37
37
  end
38
38
  end
39
39
 
40
40
  def read_json!
41
- JSON.parse(path.read, symbolize_names: true)
41
+ JSON.parse(path.read(encoding: Encoding::UTF_8), symbolize_names: true)
42
42
  end
43
43
  end
44
44
  end
@@ -31,7 +31,7 @@ module Datanorm
31
31
 
32
32
  def do_read_currently_cached_lines
33
33
  if filepath.exist?
34
- @lines = filepath.readlines(chomp: true)
34
+ @lines = filepath.readlines(chomp: true, encoding: Encoding::UTF_8)
35
35
  Tron.success(:loaded_current_file_content)
36
36
  else
37
37
  @lines = []
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: datanorm
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.6
4
+ version: 1.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - halo