foobara 0.7.3 → 0.7.5

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: b47232296ad209190a7a4779c9f09c98471259c1382c3df4d6000c746b574ded
4
- data.tar.gz: a8fecebb652f59b571c2e4192e7c8162d92378425a879cbe1b52af9a4f147978
3
+ metadata.gz: 2b1f7ca252d5b1f089c46c2bb7462cd3fc59d2140eff8ffb156d0236c5ce3c1a
4
+ data.tar.gz: a8fdfa3f7c271648abed29612e3373e7cd4b09104204a90d0f4befa771214064
5
5
  SHA512:
6
- metadata.gz: 6e0cebe29b65d89204e8f7a28ce18131d0b8c5d57f7c49c4e455d377da92c56ff2d18830f5ce560f2e8e63ca1f6ca384e601890b9a6b0eb042b5a252dedaf2b2
7
- data.tar.gz: f742b953f4a6aa14224a2615370009b8e6fb10cb927e8beabad882a8060a70701c18e52dae30311c694ff713e950219c90d2edcf26fe1476cf1fa3b914712a03
6
+ metadata.gz: 494ab94671b30308f0cec81fb32aa1801080bfeed0da2c53713f5b85a23917ad0c1eb32576d7fe7a5549765336d70673bfa46f8bc2b02b41a040f27accd1cb1e
7
+ data.tar.gz: 0c5defe3e4d38eb4cdd56194fdcd339666d726526003b97a989e227fb26ebec46ec7127a244eb5b13ced2c8386d88a55f08e401dd659681db2d1446976600ba4
data/CHANGELOG.md CHANGED
@@ -1,3 +1,12 @@
1
+ # [0.7.5] - 2026-10-20
2
+
3
+ - Make sure DetachedEntity handle reregistered types properly
4
+
5
+ # [0.7.4] - 2026-10-20
6
+
7
+ - Provide a way to register new namespaces to be reset in test suites.
8
+ Just a tiny tweak that gives a way to fix some busted external test suites.
9
+
1
10
  # [0.7.3] - 2026-10-10
2
11
 
3
12
  - More aggressively hunt down and fix types with unregistered base types
@@ -47,6 +47,24 @@ module Foobara
47
47
  @foobara_primary_key_type ||= attributes_type.element_types[primary_key_attribute]
48
48
  end
49
49
 
50
+ def handle_reregistered_types!(seen)
51
+ return if seen.include?(self)
52
+
53
+ seen << self
54
+
55
+ if attributes_type
56
+ return if seen.include?(attributes_type)
57
+
58
+ attributes_type.handle_reregistered_types!(seen)
59
+
60
+ attributes attributes_type.reference_or_declaration_data
61
+
62
+ @foobara_primary_key_type = nil
63
+ end
64
+
65
+ super
66
+ end
67
+
50
68
  alias primary_key_type foobara_primary_key_type
51
69
 
52
70
  def full_entity_name
@@ -139,6 +139,7 @@ module Foobara
139
139
  end
140
140
 
141
141
  def start! = capture_current_namespaces
142
+ def add_namespace_to_reset(namespace) = namespaces_to_reset << namespace
142
143
 
143
144
  private
144
145
 
@@ -156,8 +157,9 @@ module Foobara
156
157
  end
157
158
  end
158
159
 
160
+ # Is this really the right place to put this??
159
161
  def namespaces_to_reset
160
- [
162
+ @namespaces_to_reset ||= [
161
163
  Foobara::GlobalDomain,
162
164
  Foobara::GlobalOrganization,
163
165
  Value::Processor,
data/version.rb CHANGED
@@ -1,6 +1,6 @@
1
1
  module Foobara
2
2
  module Version
3
- VERSION = "0.7.3".freeze
3
+ VERSION = "0.7.5".freeze
4
4
  MINIMUM_RUBY_VERSION = [">= 3.4.0", "< 4.1"].freeze
5
5
  end
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: foobara
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.3
4
+ version: 0.7.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Miles Georgi