gm_x12 1.6.1 → 1.6.2

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: 5f1bcc094caf7e3e3f7af7e53bcb00da330f9bd1334d1369140a0dc876c6b302
4
- data.tar.gz: 6ce9ae9cb4c8c3631ebd49337b9a99c1cf821583467af81f8dc433f622cd7864
3
+ metadata.gz: 1026f0c49c88775932b0d61ca449da7d16df09cba8139a1f1992afdab14475fc
4
+ data.tar.gz: 1868da18975d8462570e9abb659f63a3c54a34771d6164b943fd615411239045
5
5
  SHA512:
6
- metadata.gz: 2e07c57701bfab03dc5900e65f061114b457a63519bdb5da4d603498123e071ea5c7463fa7204280ec112b96f02cefae948e707a9abc792e57b51195bfe69cd0
7
- data.tar.gz: 395d7c2731f066fda669cb24dbfe095666e51768a5844a37077e6f55f19325f243a7584efdc82f2616289164ca0b8a6f58ea3f3829521039dd734d8665514f59
6
+ metadata.gz: d58a69f2185ce6405f877d3778c59507e7cb84b6abf5ca3944c4db404961413169e4aa682e844b104baf7e1b7a306ec041e3c5075ed85bd450f49d1067042f95
7
+ data.tar.gz: 8e2a237254b46b4fb755335561174ee8fd83d26dec307740284e8e772ad5587487990c0d7f39d572d6aeef65c78c1f41d9c93d7adfc78a84be0ef243f1015624
data/README.md CHANGED
@@ -57,18 +57,18 @@ The authors of the project were inspired by the following works:
57
57
  * This project originated from App Design's X12 parser.
58
58
  * Project was forked by Sean Walberg, creating version 1.2.0 in April 2012.
59
59
  * Project was forked by Marty Petersen in November 2012, creating gm_x12.
60
- * Project was forked by GoodMeasures, Jun 2021, trying to make it work for large eligibility files, and work for Ruby 2.7.1. In particular, work for a file of about 9000 members from Wellcare.
60
+ * Project was forked by GoodMeasures, Jun 2021, trying to make it work for large eligibility files, and work for Ruby 2.7.1. In particular, work for a file of about 300K members from Wellcare.
61
61
 
62
62
 
63
63
  # Change Log
64
- 21/07/10
64
+ 21/07/10 - release 1.6.2
65
65
  * tl;dr - Made this gem actually useful.
66
66
  * 834 Definition file was fixed - it was only processing one transaction, and had
67
67
  multiple syntax errors/missing elements. At least, it now works for the client file I have
68
- * client file was ~9000 records. At the rate of processing when I forked the gem, it would have taken about a month to process a monthly file
68
+ * client file was ~300000 records. At the rate of processing when I forked the gem, it would have taken about a month to process a monthly file
69
69
  * performance fix - use string compare before using a regex, as 90% of the segment parses fail as the gem backs its way up.
70
70
  * because the gem uses tail recursion, it failed after about ~4000 eligibility records. Converted that code to using iteration instead
71
- * because the gem parses everything into memory, it consumes about 5GB before finishing. Added a callback feature for each record, so that you can process each record and then discard the memory.
71
+ * because the gem parses everything into memory, it consumes about 12GB before finishing. Added a callback feature for each record, so that you can process each record and then discard the memory.
72
72
 
73
73
  11/2/15 - release 1.5.3, 1.5.2
74
74
  * Updated 837p.xml Loop 20102AB to include REF segments
data/lib/x12/base.rb CHANGED
@@ -84,9 +84,7 @@ module X12
84
84
  p_s = possible_repeat.parse_helper(s, yield_loop_name, block)
85
85
  if p_s
86
86
  s = p_s
87
- if yield_loop_name && yield_loop_name == name
88
- block.call(possible_repeat)
89
- else
87
+ unless yield_loop_name && yield_loop_name == name
90
88
  current_element.next_repeat = possible_repeat
91
89
  end
92
90
  current_element = possible_repeat
@@ -105,6 +103,7 @@ module X12
105
103
 
106
104
  # Empty out the current element
107
105
  def set_empty!
106
+ @fields = nil
108
107
  @next_repeat = nil
109
108
  @parsed_str = nil
110
109
  self
data/lib/x12/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module X12
2
- VERSION = "1.6.1"
2
+ VERSION = "1.6.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gm_x12
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.1
4
+ version: 1.6.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Robert Mathews