ntq_excelsior_engine 0.5.0 → 1.0.1

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
  SHA256:
3
- metadata.gz: 48a08bd1c92e4e861728fbf3445600723c48cbed73ff694a1f6559ea6e207719
4
- data.tar.gz: 1c3d20ca232b9d42a4d4715d2acacdc8783c00ee2b2af9c4cf2491703ae20205
3
+ metadata.gz: df59d7f63272c718311cd243ab0488f41b321820099d3a6fe75346d2fc750afa
4
+ data.tar.gz: 333f791a1ad08cc1edf042dea3645f512ae86d8e0712b0ae4b5f0e2258159cd1
5
5
  SHA512:
6
- metadata.gz: 76ec3fd54d521dfaa970f0bc063cda42a152cd6504a9aec73ae1e7a40f974f6473c0f6ded3c89a4321823868271b9f654b777dbf0d5115504c4dcacc4dabfdd6
7
- data.tar.gz: f3f4d872bde471832fdb9615d8f0b84c27212123dcd84f02c364e168e8b5192febdcd6a9c88a432cd22257180d4e44fbdc42e86e0ac54c04f8581a895fc78ed0
6
+ metadata.gz: 36e3ef9d16b0c070f4933dcce42cd1a577afe7730b975e768373c980d361f00d1d402bad979b665da333c3e0f187ccc8f9983c44c2c8275178339fa02b550882
7
+ data.tar.gz: c2c542c700fb7291c678bd46cdb8df02255d671d4fdc39b479022bf309c2b42e1643f04b9cd893b63c1174be43f1c3446c72cdd30af9d475a41f728996537c06
@@ -18,7 +18,7 @@ module NtqExcelsiorEngine
18
18
  line.update(status: result[:status], line_errors: result[:errors], action: result[:action])
19
19
  end
20
20
  sleep 2 if NtqExcelsiorEngine.debug
21
- import.update(state: import.import_lines.in_error.any? && !NtqExcelsiorEngine.skip_import_on_errors ? 'error' : 'checked')
21
+ import.update(state: import.import_lines.in_error.any? && NtqExcelsiorEngine.skip_import_on_errors ? 'error' : 'checked')
22
22
  rescue => e
23
23
  p e.inspect
24
24
  Appsignal.send_error(e)
@@ -13,10 +13,10 @@ module NtqExcelsiorEngine
13
13
  importer = context.importer.new
14
14
  begin
15
15
  import.update(state: 'buffering')
16
-
16
+
17
17
  importer.file = import.temp_file
18
18
  lines = importer.lines
19
-
19
+
20
20
  import_lines = []
21
21
  lines.each do |line|
22
22
  import_lines << NtqExcelsiorEngine::ImportLine.new(line: line, import: import)
@@ -26,12 +26,11 @@ module NtqExcelsiorEngine
26
26
  import.update(headers: importer.detect_header_scheme, state: 'buffered')
27
27
  import.temp_file.unlink
28
28
  rescue Roo::HeaderRowNotFoundError => e
29
- message = e.message.gsub("\/i", "").gsub("/", "").slice(1..-1).chop
30
- import.update(state: 'error', error_message: 'header_not_found', backtrace: message.split(', ').join(','))
29
+ import.update(state: 'error', error_message: 'header_not_found', backtrace: e.message)
31
30
  rescue => e
32
31
  raise e if NtqExcelsiorEngine.debug
33
32
  Appsignal.send_error(e)
34
- import.update(state: 'error', backtrace: e.backtrace.join('\n'))
33
+ import.update(state: 'error', error_message: e.message, backtrace: e.backtrace.join('\n'))
35
34
  end
36
35
  end
37
36
  end
@@ -1,3 +1,3 @@
1
1
  module NtqExcelsiorEngine
2
- VERSION = "0.5.0"
2
+ VERSION = "1.0.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ntq_excelsior_engine
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kevin
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-07-04 00:00:00.000000000 Z
11
+ date: 2023-07-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails