glossarist 2.11.2 → 2.12.0

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: 8eb3d7c78878f193ed90c49d57b80201fa20db0c7a80bee39a9e7458d091135f
4
- data.tar.gz: 709a9d56a3a6956d88e2dd111ad4d29a02288f28feca43eb850fb4e2a7d83dec
3
+ metadata.gz: 4895d3a9f92f0c592e14932542e717c86d6c3b4559eec4ae133f056b99aeaae5
4
+ data.tar.gz: 0aeac1eb4550d81deba20330d9744b73144fbfb50f28e01aec1f55af9410ee9a
5
5
  SHA512:
6
- metadata.gz: 0e612d2dae7f525da03f4f677575feca311af0b93b0c8d6c7e6c54f51c3f11d86fa899eca3ab998ea1e63f366717055dd42dac20172721327cdbb99335070f4b
7
- data.tar.gz: 63ac17b342e1478973a3387fafdde5abcc12554453fd70500980f9b88207bff294ff5636bc909a68facad00c6c4f5966ad2eaa9e6442a9914e7a16ac8dda41c6
6
+ metadata.gz: edd2a440b12a2423a5725036568b85734017e400727db62f166097d71cffaef29abe588ceef136f5b25b06f9904fabafd4500fe6cf461416736b3d02e2ca1b06
7
+ data.tar.gz: ef423629a5f612d5fe6d3d84323d2acc5ae0a5a0aff9903578ac72f3dae01e997a60104d8b8f5e5bb55e7c2c667c3f9753274d804fff9913cb0fd7deed694da0
@@ -7,6 +7,7 @@ module Glossarist
7
7
  values: Glossarist::GlossaryDefinition::CONCEPT_SOURCE_TYPES
8
8
  attribute :origin, Citation
9
9
  attribute :modification, :string
10
+ attribute :sourced_from, Citation, collection: true
10
11
 
11
12
  key_value do
12
13
  map :id, to: :id
@@ -14,6 +15,7 @@ module Glossarist
14
15
  map :status, to: :status
15
16
  map :type, to: :type
16
17
  map :modification, to: :modification
18
+ map :sourced_from, to: :sourced_from
17
19
  end
18
20
  end
19
21
  end
@@ -52,8 +52,8 @@ module Glossarist
52
52
  new(
53
53
  shortname: options[:shortname] || rd&.shortname,
54
54
  version: options[:version] || rd&.version,
55
- title: options[:title] || rd&.name,
56
- description: options[:description] || rd&.description,
55
+ title: options[:title],
56
+ description: options[:description],
57
57
  owner: options[:owner],
58
58
  tags: options[:tags] || [],
59
59
  concept_count: concepts.length,
@@ -9,6 +9,7 @@ module Glossarist
9
9
  attribute :type, :string
10
10
  attribute :modification, :string
11
11
  attribute :origin, GlossCitation
12
+ attribute :sourced_from, GlossCitation, collection: true
12
13
 
13
14
  rdf do
14
15
  namespace Namespaces::GlossaristNamespace
@@ -25,6 +26,7 @@ module Glossarist
25
26
  to: :modification
26
27
 
27
28
  members :origin, link: "gloss:sourceOrigin"
29
+ members :sourced_from, link: "gloss:sourcedFrom"
28
30
  end
29
31
 
30
32
  def self.deterministic_id(source)
@@ -33,6 +35,9 @@ module Glossarist
33
35
  if origin
34
36
  parts << origin.source << origin.id << origin.version << origin.link
35
37
  end
38
+ Array(source.sourced_from).each do |sf|
39
+ parts << sf&.source << sf&.id << sf&.version << sf&.link
40
+ end
36
41
  Digest::MD5.hexdigest(parts.compact.join("|"))[0..11]
37
42
  end
38
43
  end
@@ -4,8 +4,6 @@ module Glossarist
4
4
  class RegisterData < Lutaml::Model::Serializable
5
5
  attribute :key, :string, default: -> { "register" }
6
6
  attribute :shortname, :string
7
- attribute :name, :string
8
- attribute :description, :string
9
7
  attribute :schema_version, :string
10
8
  attribute :version, :string
11
9
  attribute :owner, :string
@@ -18,10 +16,10 @@ module Glossarist
18
16
  attribute :license, :string
19
17
  attribute :tags, :string, collection: true
20
18
  attribute :translations, :hash, default: -> {}
21
- # Dataset-register fields (concept-browser Deployments). These were
22
- # previously dropped during GCR packaging, causing downstream
23
- # consumers (e.g. concept-browser's lineage-series renderer) to lose
24
- # year/ref/urn/status needed for timeline sorting and identity.
19
+
20
+ # Identity and lifecycle fields. These MUST round-trip through GCR
21
+ # packaging so consumers (concept-browser's lineage-series renderer,
22
+ # manifest year propagation, status badge logic) see them.
25
23
  attribute :ref, :string
26
24
  attribute :ref_aliases, :string, collection: true
27
25
  attribute :year, :integer
@@ -31,10 +29,15 @@ module Glossarist
31
29
  attribute :supersedes, :string
32
30
  attribute :source_repo, :string
33
31
 
32
+ # Display name + description are deliberately NOT serialized in the GCR.
33
+ # They are localized (hash) values in source register.yaml and the gem
34
+ # can't coerce them to a stable wire form without lossy .to_s coercion.
35
+ # Display metadata belongs in the deployment's site-config.yml, which
36
+ # is the SSOT for per-dataset title/description overrides. The GCR
37
+ # carries identity (ref, urn, year, status) only.
38
+
34
39
  key_value do
35
40
  map %i[id shortname], to: :shortname
36
- map "name", to: :name
37
- map "description", to: :description
38
41
  map "schema_version", to: :schema_version
39
42
  map "version", to: :version
40
43
  map "owner", to: :owner
@@ -47,6 +50,7 @@ module Glossarist
47
50
  map "license", to: :license
48
51
  map "tags", to: :tags
49
52
  map "translations", to: :translations
53
+
50
54
  map "ref", to: :ref
51
55
  map "ref_aliases", to: :ref_aliases
52
56
  map "year", to: :year
@@ -4,12 +4,14 @@ module Glossarist
4
4
  module V2
5
5
  class ConceptSource < Glossarist::ConceptSource
6
6
  attribute :origin, V2::Citation
7
+ attribute :sourced_from, V2::Citation, collection: true
7
8
 
8
9
  key_value do
9
10
  map :origin, to: :origin
10
11
  map :status, to: :status
11
12
  map :type, to: :type
12
13
  map :modification, to: :modification
14
+ map :sourced_from, to: :sourced_from
13
15
  end
14
16
  end
15
17
  end
@@ -4,12 +4,14 @@ module Glossarist
4
4
  module V3
5
5
  class ConceptSource < Glossarist::ConceptSource
6
6
  attribute :origin, V3::Citation
7
+ attribute :sourced_from, V3::Citation, collection: true
7
8
 
8
9
  key_value do
9
10
  map :origin, to: :origin
10
11
  map :status, to: :status
11
12
  map :type, to: :type
12
13
  map :modification, to: :modification
14
+ map :sourced_from, to: :sourced_from
13
15
  end
14
16
  end
15
17
  end
@@ -4,5 +4,5 @@
4
4
  #
5
5
 
6
6
  module Glossarist
7
- VERSION = "2.11.2"
7
+ VERSION = "2.12.0"
8
8
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: glossarist
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.11.2
4
+ version: 2.12.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2026-07-08 00:00:00.000000000 Z
11
+ date: 2026-07-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: lutaml-model