odin-foundation 1.0.0 → 1.0.4

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: 41cba3e1d6ec4a7cc481423fcb6ec0ddaba15b17dbe097fdb283e2f75ea75a26
4
- data.tar.gz: c114129c45abc953e0e1f8e181d6f3c35037768bd2c3f9bc89c01798492c916b
3
+ metadata.gz: e48cf0a0983a951cff7ce73bdc7855030d887ed1d42b2c6ad2d3fd7fe8a2183b
4
+ data.tar.gz: 85ee5230297ef6ae6a481c5b0fb56e7aa4df7aac789c12d06e617abfe821f985
5
5
  SHA512:
6
- metadata.gz: f66842bdf339de14334c2f83e2f4c739b8ab4f82fb5040050a687a28b002695bade7ce71c90928bb620597c502ee5aee4b5e81b837787148d4c916fe23657c64
7
- data.tar.gz: d4bfeeb7605d2de792b932da4d9b551e667ca53cbd965e27edc47d9b554ffc8dc060dd77e62bcab89290d93d551a98acba4adc5035c9ab37828df67911174971
6
+ metadata.gz: 9fb30a61553eb90ff2729e1c310b55a64ea349f58d46205c326d473783e3f12f793c79708e5d4fcf4041131fcf2d4ea77839c485507187ba398d63dbcde5b98a
7
+ data.tar.gz: 2c93ac612d779ad45d9fb749fcc6e01c21ee090f96d57f5c670a42bd87a9e8186a92867af6b132936f24620056ee2cd92d4bc7d84206dcbe12864b484bd68b76
@@ -325,6 +325,22 @@ module Odin
325
325
  return false if idx != i
326
326
  end
327
327
 
328
+ # Reject tabular if any indexed sub-array column (`field[N]`) is sparse —
329
+ # padding shorter rows with empty cells loses to the nested record-block form.
330
+ all_columns.each do |col|
331
+ next unless col.end_with?("]")
332
+
333
+ open_idx = col.rindex("[")
334
+ next if open_idx.nil? || open_idx <= 0
335
+
336
+ inner = col[(open_idx + 1)...(col.length - 1)]
337
+ next if inner.empty? || !inner.match?(/\A\d+\z/)
338
+
339
+ items.each_value do |fields|
340
+ return false unless fields.key?(col)
341
+ end
342
+ end
343
+
328
344
  columns = all_columns
329
345
  columns.sort! if @sort_paths
330
346
 
data/lib/odin/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Odin
4
- VERSION = "1.0.0"
4
+ VERSION = "1.0.4"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: odin-foundation
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - ODIN Foundation
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2026-04-06 00:00:00.000000000 Z
11
+ date: 2026-04-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bigdecimal
@@ -136,7 +136,7 @@ files:
136
136
  - lib/odin/version.rb
137
137
  homepage: https://odin.foundation
138
138
  licenses:
139
- - MIT
139
+ - Apache-2.0
140
140
  metadata: {}
141
141
  post_install_message:
142
142
  rdoc_options: []