spring 4.4.0 → 4.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: 98db88859d325bff2e76e6569e05eb10bf89baf2a07ab47f43eb6548e8ca8f1c
4
- data.tar.gz: 01e6ec88fa814c0bfe8f737a71164301b59681ea909de9bcf9fe5516eca1a2ee
3
+ metadata.gz: 1c0e16193bfb18c7246f5d4fd0789f03134c2b013ae204578f2771b460fb2e86
4
+ data.tar.gz: 84221a6cc9097b6c7762bbbab9ab1ed89e57c2783346807dc6c8fcc22d405bf1
5
5
  SHA512:
6
- metadata.gz: ebb7f95463b29f0e8c2995e19b101f0730cd0aa98ea51496fb6f8bd624253a3e4536dd5664ad2ea8ec5348cf074eb9b79f798b4b3b38adb6c717cc3ad73ca6b1
7
- data.tar.gz: e01d2b58bbace569bfdcacec81b852427a5bdf5efdf724be560598f13dbabbf32502aec90aa899d0fdf3b16e0255a1ada40d9b0ac7a4cb74a3d3f6f1352342c4
6
+ metadata.gz: 8fbb8005a56cc2d9a24f33a0f2e5d7a3f318a5d99819402aa239f8dd13ef08f85d4409d5c2969a216bf91a46f8585b884122454c05f0dcc22068174fc72ff674
7
+ data.tar.gz: 10eda5daa0ba53c15f30894df2c48942f06287e94e663a0d10972ba1f49e8aa29c6fcb52747c70ce5db98c6736d62c7f11d9d8731842fd089aeb60118ded4a31
data/README.md CHANGED
@@ -17,7 +17,7 @@ boot it every time you run a test, rake task or migration.
17
17
  ## Compatibility
18
18
 
19
19
  * Ruby versions: MRI 3.1+
20
- * Rails versions: 6.0+
20
+ * Rails versions: 7.1+
21
21
  * Bundler v2.1+
22
22
 
23
23
  Spring makes extensive use of `Process.fork`, so won't be able to
@@ -129,8 +129,9 @@ module Spring
129
129
 
130
130
  if defined?(Rails) && Rails.application
131
131
  watcher.add Rails.application.paths["config/initializers"]
132
- Rails::Engine.descendants.each do |engine|
133
- if engine.root.to_s.start_with?(Rails.root.to_s)
132
+ rails_root = Rails.root.to_s
133
+ Rails::Engine.subclasses.each do |engine|
134
+ if engine.root.to_s.start_with?(rails_root)
134
135
  watcher.add engine.paths["config/initializers"].expanded
135
136
  end
136
137
  end
@@ -377,10 +378,10 @@ module Spring
377
378
  Spring.failsafe_thread {
378
379
  begin
379
380
  _, status = Process.wait2 pid
380
- log "#{pid} exited with #{status.exitstatus}"
381
+ log "#{pid} exited with #{status.exitstatus || status.inspect}"
381
382
 
382
383
  streams.each(&:close)
383
- client.puts(status.exitstatus)
384
+ client.puts(status.exitstatus || status.to_i)
384
385
  client.close
385
386
  ensure
386
387
  @mutex.synchronize { @waiting.delete pid }
@@ -184,11 +184,16 @@ module Spring
184
184
  suspend_resume_on_tstp_cont(pid)
185
185
 
186
186
  forward_signals(application)
187
- status = application.read.to_i
187
+ status = application.read
188
+ log "got exit status #{status.inspect}"
188
189
 
189
- log "got exit status #{status}"
190
+ # Status should always be an integer. If it is empty, something unexpected must have happened to the server.
191
+ if status.to_s.strip.empty?
192
+ log "unexpected empty exit status, app crashed?"
193
+ exit 1
194
+ end
190
195
 
191
- exit status
196
+ exit status.to_i
192
197
  else
193
198
  log "got no pid"
194
199
  exit 1
@@ -1,3 +1,3 @@
1
1
  module Spring
2
- VERSION = "4.4.0"
2
+ VERSION = "4.4.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spring
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.4.0
4
+ version: 4.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jon Leighton
@@ -71,7 +71,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
71
71
  - !ruby/object:Gem::Version
72
72
  version: '0'
73
73
  requirements: []
74
- rubygems_version: 3.6.7
74
+ rubygems_version: 4.0.3
75
75
  specification_version: 4
76
76
  summary: Rails application preloader
77
77
  test_files: []