typed_eav 0.7.1 → 0.8.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.
Files changed (46) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +87 -2
  3. data/README.md +79 -1505
  4. data/RELEASING.md +81 -0
  5. data/docs/adr/0001-collapse-column-mapping-stack.md +28 -0
  6. data/docs/adr/0002-entity-query-orchestration.md +33 -0
  7. data/docs/adr/0003-keep-event-dispatcher-broker.md +41 -0
  8. data/docs/adr/0004-field-family-intermediate-bases.md +49 -0
  9. data/docs/adr/0005-keep-phase-six-modules-independent.md +48 -0
  10. data/docs/adr/0006-include-missing-via-set-complement.md +77 -0
  11. data/docs/adr/0007-visibility-versus-mutation-relations.md +33 -0
  12. data/docs/adr/0008-partial-covering-scalar-indexes.md +83 -0
  13. data/docs/adr/0009-string-search-indexing.md +110 -0
  14. data/docs/adr/0010-planner-statistics-policy.md +109 -0
  15. data/docs/adr/0011-multi-filter-query-strategy.md +111 -0
  16. data/docs/adr/0012-cross-scope-administrative-query-policy.md +76 -0
  17. data/docs/adr/0013-durable-versioning-and-field-deletion.md +125 -0
  18. data/docs/adr/index.md +101 -0
  19. data/docs/getting-started.md +79 -0
  20. data/docs/guides/architecture.md +125 -0
  21. data/docs/guides/bulk-operations.md +205 -0
  22. data/docs/guides/csv-import.md +88 -0
  23. data/docs/guides/development.md +73 -0
  24. data/docs/guides/events-and-versioning.md +360 -0
  25. data/docs/guides/fields.md +342 -0
  26. data/docs/guides/performance.md +107 -0
  27. data/docs/guides/queries.md +188 -0
  28. data/docs/guides/schema.md +134 -0
  29. data/docs/guides/scoping.md +254 -0
  30. data/docs/guides/upgrading.md +26 -0
  31. data/docs/guides/usage.md +259 -0
  32. data/docs/index.md +44 -0
  33. data/docs/maintaining.md +82 -0
  34. data/docs/reference/api.md +133 -0
  35. data/docs/reference/configuration.md +64 -0
  36. data/docs/reference/index.md +16 -0
  37. data/lib/typed_eav/bulk_read.rb +143 -22
  38. data/lib/typed_eav/entity_query.rb +154 -2
  39. data/lib/typed_eav/has_typed_eav/dirty_tracking.rb +207 -0
  40. data/lib/typed_eav/has_typed_eav.rb +6 -2
  41. data/lib/typed_eav/scalar_query.rb +228 -0
  42. data/lib/typed_eav/schema_portability/preview.rb +379 -0
  43. data/lib/typed_eav/schema_portability.rb +20 -0
  44. data/lib/typed_eav/version.rb +1 -1
  45. data/lib/typed_eav.rb +1 -0
  46. metadata +38 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 312b444b0c7b29eb298af1ef5bba02d3ba56ad811399b3ffcd2dfd2afd88267b
4
- data.tar.gz: cfa3ca85088eaff46dff6657d098f9fcf38fec9129b53792cfb37cc19e4358ad
3
+ metadata.gz: 0dff0e04ca4b32e4e63fbafe6cb3531ba3626f30a68e0bde6cb99196a6e7563e
4
+ data.tar.gz: 300ff1681cb7274d624cf9f6427a771fd003efe87dcd75d25a5ed08ffec69314
5
5
  SHA512:
6
- metadata.gz: abcb3cde1dc9d09da1ea014165c245d74aa2ef2f5fd566ecc9f86343b8e30b1ca32bcc10eb9735a06a23641bb0ccef7c1078d2be288a724a20b6d7e44468e6d9
7
- data.tar.gz: b259edd0ece6e756569a151194368fc0adda83063d56683f9113d6373c0eede174cb545f9d1ca0ccc70e2dd512239494299f3da8608567aa5e47989e3b780eb3
6
+ metadata.gz: 58b786e5c7f2679b0f94c463f3eaa1e341ca765f19b8fe539fa7366dba9604fdb8f29987effafc3281a77e4e65b61c47e06043d1fa7c63456f4b4fd59dc51247
7
+ data.tar.gz: a5847413bc3b562802705359c916de7eadba21e9c4aba9a281e46194cb52c2269d27c2f4a6908a31a4bc3fbaf546d30205395a0d4aebf50aee6f19a7c49134e7
data/CHANGELOG.md CHANGED
@@ -7,6 +7,89 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [0.8.1] - 2026-09-08
11
+
12
+ Documentation-focused patch release; no runtime API or database migration changes.
13
+
14
+ ### Added
15
+
16
+ - Browsable documentation site with grouped sidebar navigation, a public API and
17
+ configuration reference, and a user-facing summary of design decisions.
18
+ - Guides for CSV mapping, schema import/export and snapshots, defaults,
19
+ missing-value queries, bulk-write results, and public partition helpers.
20
+ - GitHub Pages build and deployment workflow with local link and anchor checks.
21
+ The site renders its changelog from the canonical root file.
22
+ - Public documentation Markdown included in the gem package.
23
+
24
+ ### Changed
25
+
26
+ - Shortened the README into an installation and discovery entry point, preserving
27
+ detailed examples and contracts in linked guides.
28
+ - Corrected scope-resolver examples to use the documented tuple return shape.
29
+ - Required documentation review after every repository change in both agent
30
+ instruction files.
31
+
32
+ ## [0.8.0] - 2026-09-04
33
+
34
+ New SQL-backed query APIs, selective/preloaded bulk reads, logical dirty
35
+ tracking, and read-only schema previews. Existing read defaults are preserved;
36
+ no database migrations or new runtime dependencies are required.
37
+
38
+ ### Added
39
+
40
+ - Read-only `SchemaPortability.preview_schema` compares exact-partition
41
+ portable schemas with current definitions, exposing field/section/option
42
+ differences, conditional import actions, and risk flags. Type swaps remain
43
+ blocked and omitted definitions are not treated as deletions. Previewing
44
+ never applies changes or guarantees a later import's success. (#51)
45
+ - `saved_typed_eav_changes` exposes the last successful host save's logical
46
+ changes inside `after_save` callbacks. Failed saves preserve the prior
47
+ snapshot; no-op saves, reload, and rollback have explicit lifecycle
48
+ semantics independent of audit/versioning. (#48)
49
+ - Database-backed `aggregate_typed_eav` min/max/sum for Integer and Decimal
50
+ field families, including Percentage. Decimal precision, caller host sets,
51
+ and explicit empty/NULL semantics are preserved; references and multi-cell
52
+ Currency are rejected instead of silently aggregated. (#50)
53
+ - SQL-backed distinct typed values, exact distinct counts, and bounded
54
+ per-value host counts. Caller host filters/pagination and field-definition
55
+ precedence are retained; explicit NULL, false, and empty strings have
56
+ documented semantics without host or Value hydration. (#49)
57
+ - Explicit `source: :preloaded` bulk reads reuse caller-loaded Value graphs,
58
+ including unsaved edits, with one batched definition lookup and no duplicate
59
+ Value hydration. Incomplete required preloads fail clearly; fresh database
60
+ reads remain the default. (#46)
61
+ - Pending logical typed-value changes via `typed_eav_changes`, covering
62
+ host-associated named/nested edits and marked removals without loading
63
+ untouched Value collections. Failed saves retain validation feedback and
64
+ pending changes; this API is separate from persisted audit history. (#47)
65
+ - Database-backed `order_typed_eav` for scalar fields, with explicit NULL
66
+ placement and stable primary-key tie-breaking. Caller host filters and
67
+ partition-definition precedence are preserved without Value hydration. (#44)
68
+ - Field-selective bulk reads with `typed_eav_hash_for(records, fields: names)`.
69
+ Selected winning field IDs narrow value loading before hydration; omitted
70
+ `fields:` preserves all-fields reads. Empty, duplicate, unknown, and
71
+ partition-specific names have explicit projection semantics. (#45)
72
+
73
+ ### Compatibility and usage notes
74
+
75
+ - Typed sorting and summaries select one effective field definition. Scope
76
+ arguments do not authorize or filter host records: retain tenant and access
77
+ filters on the caller's Active Record relation. All-partitions mode and
78
+ unsupported collection/multi-cell operations fail explicitly.
79
+ - Distinct lists and grouped counts default to 100 values (maximum 1,000),
80
+ ordered by value rather than frequency. Exact distinct counts include the
81
+ explicit NULL category; missing rows are omitted. Numeric min/max/sum retain
82
+ Integer/BigDecimal types and do not aggregate reference IDs or currencies.
83
+ - Preloaded reads are explicit in-memory value snapshots with a current
84
+ definition lookup; database reads remain the default. Dirty/saved changes
85
+ describe host-associated editing and save state, not durable audit history
86
+ or independently executed bulk SQL writes.
87
+ - Schema previews are advisory, exact-partition comparisons. They neither
88
+ apply changes nor reserve the schema or guarantee a later import's success.
89
+ - Local verification: 1,404 examples, 0 failures; 160 Ruby files lint-clean.
90
+ The release workflow additionally verifies the supported compatibility
91
+ matrix and the exact packaged artifact before publication.
92
+
10
93
  ## [0.7.1] - 2026-09-04
11
94
 
12
95
  A focused patch release for inherited Active Record hosts and multi-partition
@@ -591,7 +674,7 @@ without giving up the existing single-scope ergonomics.
591
674
  4. Optional: declare `parent_scope_method:` on hosts that have an in-tenant
592
675
  partition. Existing single-scope models continue to work without changes.
593
676
 
594
- See the README ["Migrating from v0.1.x"](README.md#migrating-from-v01x)
677
+ See the README ["Migrating from v0.1.x"](docs/guides/upgrading.md#migrating-from-v01x)
595
678
  section for the full guidance, including the orphan-parent invariant and
596
679
  worked examples.
597
680
 
@@ -609,7 +692,9 @@ worked examples.
609
692
 
610
693
  Initial release.
611
694
 
612
- [Unreleased]: https://github.com/dchuk/typed_eav/compare/v0.7.1...HEAD
695
+ [Unreleased]: https://github.com/dchuk/typed_eav/compare/v0.8.1...HEAD
696
+ [0.8.1]: https://github.com/dchuk/typed_eav/releases/tag/v0.8.1
697
+ [0.8.0]: https://github.com/dchuk/typed_eav/releases/tag/v0.8.0
613
698
  [0.7.1]: https://github.com/dchuk/typed_eav/releases/tag/v0.7.1
614
699
  [0.7.0]: https://github.com/dchuk/typed_eav/releases/tag/v0.7.0
615
700
  [0.6.0]: https://github.com/dchuk/typed_eav/releases/tag/v0.6.0