dry-system 1.2.1 → 1.2.3

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: 2bfcd9d967376239fe52f2271b94ebb88f3842caac283d631524db63d57cbf0e
4
- data.tar.gz: eaa00945487dd187d6ebf3ae880b711630fcd1a7db6175638ef8cbad189aeacc
3
+ metadata.gz: f6e2bd6b5eeb03f260f1bf95def5a6dd7b1a419aa2e57301805fc37f43ffa08c
4
+ data.tar.gz: 18d1e11ad33a6e725b3eb049662957652120edcc2ce5da31847d13f511df65d8
5
5
  SHA512:
6
- metadata.gz: b80ee5f708536fc62ee2991dea47a8fa15dc00f0c4e6dfa38140a338d551c0cc2b3734d7f2d7cf63c912168830257d749b49858104dcc1f0b318c5bc6fddd8c8
7
- data.tar.gz: b03e2f4e70c2f96faf1794856d8126ff911f89d643237746f4e0dda06a399deb8003501df175659fa213a416c8016b138297a7085cd03e0cbd73d9ce97829682
6
+ metadata.gz: b80e0a016030c542c963155140f30d15eb62c463c29ed1ba94d79378371fd11d2f2a7c4ea13cd0c11bbea3210cda2262cacde67ce9f8c50412e25a98c292a3a7
7
+ data.tar.gz: 35473d55c1434e8427c1d297868d65d2a31c2ebf559c50618712e97293f0d1c8ecd726945a94e4bde6bcbcfd7ef50837590f5e36c4a3a8396d52bce99a988e80
data/CHANGELOG.md CHANGED
@@ -1,5 +1,26 @@
1
1
  <!--- DO NOT EDIT THIS FILE - IT'S AUTOMATICALLY GENERATED VIA DEVTOOLS --->
2
2
 
3
+ ## 1.2.3 2025-07-29
4
+
5
+
6
+ ### Fixed
7
+
8
+ - Re-register components from manifest registrars in apps that reload the container (e.g. when
9
+ using dry-rails and Rails development mode) (via #286, @alassek)
10
+
11
+
12
+ [Compare v1.2.2...v1.2.3](https://github.com/dry-rb/dry-system/compare/v1.2.2...v1.2.3)
13
+
14
+ ## 1.2.2 2025-01-31
15
+
16
+
17
+ ### Fixed
18
+
19
+ - Syntax errors on 3.3.0 (@flash-gordon, see #284)
20
+
21
+
22
+ [Compare v1.2.1...v1.2.2](https://github.com/dry-rb/dry-system/compare/v1.2.1...v1.2.2)
23
+
3
24
  ## 1.2.1 2025-01-08
4
25
 
5
26
 
@@ -325,10 +325,10 @@ module Dry
325
325
  [providers, auto_registrar, manifest_registrar, importer].each(&:finalize!)
326
326
 
327
327
  @__finalized__ = true
328
-
329
- self.freeze if freeze
330
328
  end
331
329
 
330
+ self.freeze if freeze
331
+
332
332
  self
333
333
  end
334
334
 
@@ -484,6 +484,15 @@ module Dry
484
484
  config.root
485
485
  end
486
486
 
487
+ # @api public
488
+ def register(key, *)
489
+ super
490
+
491
+ hooks[:after_register].each { |hook| instance_exec(key, &hook) }
492
+
493
+ self
494
+ end
495
+
487
496
  # @api public
488
497
  def resolve(key)
489
498
  load_component(key) unless finalized?
@@ -33,7 +33,7 @@ module Dry
33
33
 
34
34
  # @api private
35
35
  def call(component)
36
- require(root.join(config.registrations_dir, component.root_key.to_s))
36
+ load(root.join(config.registrations_dir, "#{component.root_key}#{RB_EXT}"))
37
37
  end
38
38
 
39
39
  # @api private
@@ -24,7 +24,7 @@ module Dry
24
24
  end
25
25
 
26
26
  # @api private
27
- def monitor(key, **options, &)
27
+ def monitor(key, **options, &block)
28
28
  notifications = self[:notifications]
29
29
 
30
30
  resolve(key).tap do |target|
@@ -32,7 +32,7 @@ module Dry
32
32
 
33
33
  if block_given?
34
34
  proxy.monitored_methods.each do |meth|
35
- notifications.subscribe(:monitoring, target: key, method: meth, &)
35
+ notifications.subscribe(:monitoring, target: key, method: meth, &block)
36
36
  end
37
37
  end
38
38
 
@@ -37,7 +37,7 @@ module Dry
37
37
  # @see Dry::System::Provider::SourceDSL
38
38
  #
39
39
  # @api private
40
- def for(name:, group: nil, superclass: nil, &)
40
+ def for(name:, group: nil, superclass: nil, &block)
41
41
  superclass ||= self
42
42
 
43
43
  ::Class.new(superclass) { |klass|
@@ -51,7 +51,7 @@ module Dry
51
51
  end # end
52
52
  RUBY
53
53
 
54
- SourceDSL.evaluate(klass, &) if block_given?
54
+ SourceDSL.evaluate(klass, &block) if block_given?
55
55
  }
56
56
  end
57
57
 
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Dry
4
4
  module System
5
- VERSION = "1.2.1"
5
+ VERSION = "1.2.3"
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dry-system
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.1
4
+ version: 1.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Piotr Solnica
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-01-08 00:00:00.000000000 Z
11
+ date: 2025-07-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: dry-auto_inject