quilt_rails 1.3.2 → 1.3.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9cee30519a782a6fddf8ef312f68e594872ff80a832a776549c20c85775fa5e4
4
- data.tar.gz: bb9c1ac6a10090dcb245eef5ac5523963319e413f6c19709da7a72f2c72508c5
3
+ metadata.gz: 23c9ede78194c6dd73367b54499f3b9359aa1274503c2363e11b56a7753eb599
4
+ data.tar.gz: 44251849018fe5e5e66b414de73ac1b9cbe0ef6285238e2c25259d95e2997597
5
5
  SHA512:
6
- metadata.gz: dcc8be76612a56b7f8a9b0874d3e8efee17fb6b2eb41ff426113f01e84431abc7418d74b8c1b533561fe9bfb7f647a6eae64fda37d5899fd1c1348ef2978bccd
7
- data.tar.gz: ea5953b8ec5e4f4996eaf4f1d611b32c83d0f9b11809a41f478fd6d6123296321d5f74b9e59046001ce4a8bbdf9171531bc91d19e27445f1a3bf840171910e21
6
+ metadata.gz: '0922dba782dcfef3fc604195ca82191bef7835924252402c9041807ce767374f3e557e076d0b8fbc0b82cc75df9b974368c7d910a4f8be055b7f6db856bb6109'
7
+ data.tar.gz: a8c56ce33232eb7dc424630df23086a8e161d77ef23f3e654bc54b12d2eb7378e4235c118fda5e6b45de57ddf07a9760cd034310537e452f4736733262277456
@@ -10,10 +10,14 @@ module Quilt
10
10
  url = "#{Quilt.configuration.react_server_protocol}://#{Quilt.configuration.react_server_host}"
11
11
  ReactRenderable.log("[ReactRenderable] proxying to React server at #{url}")
12
12
 
13
- reverse_proxy(url) do |callbacks|
14
- callbacks.on_response do |status_code, _response|
15
- ReactRenderable.log("[ReactRenderable] #{url} returned #{status_code}")
13
+ begin
14
+ reverse_proxy(url) do |callbacks|
15
+ callbacks.on_response do |status_code, _response|
16
+ ReactRenderable.log("[ReactRenderable] #{url} returned #{status_code}")
17
+ end
16
18
  end
19
+ rescue Errno::ECONNREFUSED
20
+ raise ReactServerNoResponseError, url
17
21
  end
18
22
  end
19
23
 
@@ -24,5 +28,12 @@ module Quilt
24
28
  Rails.logger.info(string)
25
29
  end
26
30
  end
31
+
32
+ class ReactServerNoResponseError < StandardError
33
+ def initialize(url)
34
+ # rubocop:disable LineLength
35
+ super "Errno::ECONNREFUSED: Waiting for React server to boot up. If this error presists verify that @shopify/react-server is configured on #{url}"
36
+ end
37
+ end
27
38
  end
28
39
  end
@@ -1,4 +1,4 @@
1
1
  # frozen_string_literal: true
2
2
  module Quilt
3
- VERSION = "1.3.2"
3
+ VERSION = "1.3.3"
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: quilt_rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.2
4
+ version: 1.3.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mathew Allen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-08-20 00:00:00.000000000 Z
11
+ date: 2019-08-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: railties