event_engine-event_definition 0.4.0 → 0.4.1

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: d2f15e08e449f4492d0231c96e10abbfa83de7b00debf51dc42fa87944145f81
4
- data.tar.gz: 070cb9065ee0f9528b8fb2a45374fbcad317a90ada0971cc8dcf1616f794a507
3
+ metadata.gz: 39cc03426c46b2aea116a8fe255de12693b6d6b2e0103a8be66c9631bb0ca992
4
+ data.tar.gz: 0d991cfccb966f627bc6007a5fb07f0216e1b97b9cdab7c9398f4c03c0a12e3c
5
5
  SHA512:
6
- metadata.gz: d6af9ac96261bbd8ea3342b8daa05c830543cc3bc1f0d6dcd5fb98ab7b2db7fe9e7cb831d7c7687e4ada1157656245a7db0ffb82aa0c00b9d0056b57145560e7
7
- data.tar.gz: d2c72bd2e7b6c1549911b276746c3910e24dad7e0919ea81fffd2a1a892948d8d28eb7f5a3ecb96aff5095a53c8533fba979ae23ca732ab989da10bc456705a0
6
+ metadata.gz: 8bef449049d004b6b9efce764aaeaa6459efe5d0af9dc8b218ba5793d3dba955bccf0e1547d5afc6fc89da7f579c1b7882c04d2a492897fab92ac1d1ba1c91df
7
+ data.tar.gz: '07728eddfd89b0a43c27845b7701b3e648fc69d8d62ccd4758f69eae136e360ad567febd4297e8fa87fb3a95b077b1c3d8b17baa67a4eb7bfb55fdbaaf776782'
data/CHANGELOG.md CHANGED
@@ -5,6 +5,17 @@ All notable changes to this gem are documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [Unreleased]
9
+
10
+ ## [0.4.1] - 2026-10-23
11
+
12
+ ### Fixed
13
+
14
+ - `event_definition:generate` wrote every event into `schema.json` with
15
+ `"event_version": null`, since nothing assigned a version. An event with no
16
+ version is now written at version 1. Generation still does not raise the
17
+ version when an event's fingerprint changes.
18
+
8
19
  ## [0.4.0] - 2026-09-25
9
20
 
10
21
  ### Added
@@ -2,6 +2,6 @@
2
2
 
3
3
  module EventEngine
4
4
  module Definition
5
- VERSION = "0.4.0"
5
+ VERSION = "0.4.1"
6
6
  end
7
7
  end
@@ -12,6 +12,8 @@ module EventEngine
12
12
 
13
13
  SCHEMA_FILENAME = "schema.json"
14
14
 
15
+ FIRST_VERSION = 1
16
+
15
17
  HEADER = <<~RUBY.freeze
16
18
  # This file is authoritative in production.
17
19
  # It is generated from this pack's EventDefinitions.
@@ -61,7 +63,9 @@ module EventEngine
61
63
  end
62
64
 
63
65
  def schemas(event_schema)
64
- event_schema.schemas_by_event.values.flat_map(&:values).map(&:to_h)
66
+ event_schema.schemas_by_event.values.flat_map(&:values).map do |schema|
67
+ schema.to_h.merge(event_version: schema.event_version || FIRST_VERSION)
68
+ end
65
69
  end
66
70
 
67
71
  def write_helper(event_schema)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: event_engine-event_definition
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - tylercschneider