pubid 2.0.57 → 2.0.58
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 +4 -4
- data/lib/pubid/etsi/CLAUDE.md +18 -0
- data/lib/pubid/etsi/urn_generator.rb +4 -1
- data/lib/pubid/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: d92689d27609bdbd6fc6f2ded3fa384c6f928ab6befc08695d05e1f5490c4291
|
|
4
|
+
data.tar.gz: ab8474f1e5d2c1a9a4a54aa8fd34a589a787293905764a347880e79419e02b63
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1275b3fde48d190f3e5c3da162cd7a628ef5def89c6b3d557058b385c4d49628b81ce0ffa7d09ec3412cb9deb02484a90cb317b4c0c1d79a0e563f9ac153f763
|
|
7
|
+
data.tar.gz: 12bc0d300a227672d4b9f174cde9f863e8ca86c2f96372f80ce6d8455a091106ab00a076fc77616ca604b41342e0bf8081bbd6b782dac98bd535ad8403f68956
|
data/lib/pubid/etsi/CLAUDE.md
CHANGED
|
@@ -41,3 +41,21 @@ is `:int` (`core: [["number", :int]]`), and the codec refuses a String there.
|
|
|
41
41
|
`minor` and `day` are placed although no pass fixture sets them, because
|
|
42
42
|
`EtsiStandard`'s `key_value` block maps them: a schema must place every key
|
|
43
43
|
the mapping can write, not only the keys the corpus shows.
|
|
44
|
+
|
|
45
|
+
## Official URN: the month 08/09 octal trap (repaired)
|
|
46
|
+
|
|
47
|
+
`UrnGenerator#urn_date` fed the zero-padded `month` **string** to
|
|
48
|
+
`format('%02d', …)`, and `%d` reads its argument through `Integer()` — which
|
|
49
|
+
refuses `"08"`/`"09"` as octal look-alikes. So every corpus row dated
|
|
50
|
+
`(YYYY-08)`/`(YYYY-09)` parsed and rendered fine but **`to_urn` raised
|
|
51
|
+
`ArgumentError`** — the three-engine differential reported these rows as
|
|
52
|
+
"ruby rejects" against rust/ts (which render
|
|
53
|
+
`urn:etsi:<type>:<code>:<version>:<yyyy>-<mm>` for every month). The fix is
|
|
54
|
+
`date.month.to_i` before the format (decimal cast); the etsi_pfs parity spec
|
|
55
|
+
had pinned the raise as a known defect and the pin flipped with the fix
|
|
56
|
+
(`spec/pubid/etsi_pfs/parity_spec.rb`, "official URN segments"). Locked by
|
|
57
|
+
`spec/pubid/etsi/urn_spec.rb`. The testsuite corpus rows for those months
|
|
58
|
+
carry no `urn:` representation precisely because the generator crashed when
|
|
59
|
+
the corpus round exported them — a future etsi corpus round can now emit
|
|
60
|
+
them. (hand-off: etsi-differential-rows.)
|
|
61
|
+
|
|
@@ -32,7 +32,10 @@ module Pubid
|
|
|
32
32
|
|
|
33
33
|
date = identifier.date
|
|
34
34
|
if date.month
|
|
35
|
-
|
|
35
|
+
# `month` is a zero-padded string ("09"); `%d` reads it through
|
|
36
|
+
# Integer(), which refuses "08"/"09" as octal look-alikes —
|
|
37
|
+
# cast to a decimal integer first.
|
|
38
|
+
"#{date.year}-#{format('%02d', date.month.to_i)}"
|
|
36
39
|
else
|
|
37
40
|
date.year.to_s
|
|
38
41
|
end
|
data/lib/pubid/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: pubid
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.0.
|
|
4
|
+
version: 2.0.58
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ribose Inc.
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-11-
|
|
11
|
+
date: 2026-11-27 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: lutaml-model
|