fibered_mysql2 0.3.0 → 0.3.1

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: b26f8b41b8008965bde3defa980553ef3f5ee82dc750d510f98d1728db1dfb2b
4
- data.tar.gz: 8a6ff673f5be6e742bb010c217061a78012206d515cd2450efaf17159d208d90
3
+ metadata.gz: 8cf06a5be94da99bc7d1e0de4b5268ff04a72fd7671e6c4d522186d1ea67dd0b
4
+ data.tar.gz: 931890052763e7fcf2f1ffb7925848004dc54c4c583f89d24c258cbe1537a67a
5
5
  SHA512:
6
- metadata.gz: a2f5e70e6f236fcd7fea48e50bc09e33571d2d301e0f1eaa204f90d04e22fbd80585de33c3afd1dea13dea40076a56a158e2e39eeed7203c4b6c6b79b5a6fce4
7
- data.tar.gz: 3b5e28792b82a53a7c43e937b30d953617c31399c6a34a74aba2e8d8e454661dc9a2c19728e6ccffa21b6e1a8481052073ccc48f2db84567baa5fb4bfe2b6707
6
+ metadata.gz: 42cab06e4e9bccd07df1436db08c8fb0e8038027690bc03cc58a34eab99ecfd6cccedbdde27f63f9607ce391bea3de8d941cc720775deb7c0c7d65134f405bae
7
+ data.tar.gz: be4a1bd1357e9d51e2e76e48f93ede62f8b7c3cb9cf515a042cf9d10f4d2afe63721349f5afe65a67d2cc9246741aab39a80c7aa903bafde77d95d75c026cd05
data/CHANGELOG.md CHANGED
@@ -4,6 +4,10 @@ Inspired by [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
4
4
 
5
5
  Note: this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## [0.3.1] - 2024-10-30
8
+ ### Fixed
9
+ - Fixed bug in FiberedMysqlAdapter.new_client that was causing `uninitialized constant` errors.
10
+
7
11
  ## [0.3.0] - 2024-10-23
8
12
  ### Added
9
13
  - Support for Rails 7.0.
data/Gemfile.lock CHANGED
@@ -1,74 +1,74 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- fibered_mysql2 (0.3.0)
4
+ fibered_mysql2 (0.3.1)
5
5
  em-synchrony (~> 1.0)
6
6
  rails (>= 6.1, < 7.1)
7
7
 
8
8
  GEM
9
9
  remote: https://rubygems.org/
10
10
  specs:
11
- actioncable (7.0.8.5)
12
- actionpack (= 7.0.8.5)
13
- activesupport (= 7.0.8.5)
11
+ actioncable (7.0.8.6)
12
+ actionpack (= 7.0.8.6)
13
+ activesupport (= 7.0.8.6)
14
14
  nio4r (~> 2.0)
15
15
  websocket-driver (>= 0.6.1)
16
- actionmailbox (7.0.8.5)
17
- actionpack (= 7.0.8.5)
18
- activejob (= 7.0.8.5)
19
- activerecord (= 7.0.8.5)
20
- activestorage (= 7.0.8.5)
21
- activesupport (= 7.0.8.5)
16
+ actionmailbox (7.0.8.6)
17
+ actionpack (= 7.0.8.6)
18
+ activejob (= 7.0.8.6)
19
+ activerecord (= 7.0.8.6)
20
+ activestorage (= 7.0.8.6)
21
+ activesupport (= 7.0.8.6)
22
22
  mail (>= 2.7.1)
23
23
  net-imap
24
24
  net-pop
25
25
  net-smtp
26
- actionmailer (7.0.8.5)
27
- actionpack (= 7.0.8.5)
28
- actionview (= 7.0.8.5)
29
- activejob (= 7.0.8.5)
30
- activesupport (= 7.0.8.5)
26
+ actionmailer (7.0.8.6)
27
+ actionpack (= 7.0.8.6)
28
+ actionview (= 7.0.8.6)
29
+ activejob (= 7.0.8.6)
30
+ activesupport (= 7.0.8.6)
31
31
  mail (~> 2.5, >= 2.5.4)
32
32
  net-imap
33
33
  net-pop
34
34
  net-smtp
35
35
  rails-dom-testing (~> 2.0)
36
- actionpack (7.0.8.5)
37
- actionview (= 7.0.8.5)
38
- activesupport (= 7.0.8.5)
36
+ actionpack (7.0.8.6)
37
+ actionview (= 7.0.8.6)
38
+ activesupport (= 7.0.8.6)
39
39
  rack (~> 2.0, >= 2.2.4)
40
40
  rack-test (>= 0.6.3)
41
41
  rails-dom-testing (~> 2.0)
42
42
  rails-html-sanitizer (~> 1.0, >= 1.2.0)
43
- actiontext (7.0.8.5)
44
- actionpack (= 7.0.8.5)
45
- activerecord (= 7.0.8.5)
46
- activestorage (= 7.0.8.5)
47
- activesupport (= 7.0.8.5)
43
+ actiontext (7.0.8.6)
44
+ actionpack (= 7.0.8.6)
45
+ activerecord (= 7.0.8.6)
46
+ activestorage (= 7.0.8.6)
47
+ activesupport (= 7.0.8.6)
48
48
  globalid (>= 0.6.0)
49
49
  nokogiri (>= 1.8.5)
50
- actionview (7.0.8.5)
51
- activesupport (= 7.0.8.5)
50
+ actionview (7.0.8.6)
51
+ activesupport (= 7.0.8.6)
52
52
  builder (~> 3.1)
53
53
  erubi (~> 1.4)
54
54
  rails-dom-testing (~> 2.0)
55
55
  rails-html-sanitizer (~> 1.1, >= 1.2.0)
56
- activejob (7.0.8.5)
57
- activesupport (= 7.0.8.5)
56
+ activejob (7.0.8.6)
57
+ activesupport (= 7.0.8.6)
58
58
  globalid (>= 0.3.6)
59
- activemodel (7.0.8.5)
60
- activesupport (= 7.0.8.5)
61
- activerecord (7.0.8.5)
62
- activemodel (= 7.0.8.5)
63
- activesupport (= 7.0.8.5)
64
- activestorage (7.0.8.5)
65
- actionpack (= 7.0.8.5)
66
- activejob (= 7.0.8.5)
67
- activerecord (= 7.0.8.5)
68
- activesupport (= 7.0.8.5)
59
+ activemodel (7.0.8.6)
60
+ activesupport (= 7.0.8.6)
61
+ activerecord (7.0.8.6)
62
+ activemodel (= 7.0.8.6)
63
+ activesupport (= 7.0.8.6)
64
+ activestorage (7.0.8.6)
65
+ actionpack (= 7.0.8.6)
66
+ activejob (= 7.0.8.6)
67
+ activerecord (= 7.0.8.6)
68
+ activesupport (= 7.0.8.6)
69
69
  marcel (~> 1.0)
70
70
  mini_mime (>= 1.1.0)
71
- activesupport (7.0.8.5)
71
+ activesupport (7.0.8.6)
72
72
  concurrent-ruby (~> 1.0, >= 1.0.2)
73
73
  i18n (>= 1.6, < 2)
74
74
  minitest (>= 5.1)
@@ -103,7 +103,7 @@ GEM
103
103
  i18n (1.14.6)
104
104
  concurrent-ruby (~> 1.0)
105
105
  json (2.7.2)
106
- loofah (2.22.0)
106
+ loofah (2.23.1)
107
107
  crass (~> 1.0.2)
108
108
  nokogiri (>= 1.12.0)
109
109
  mail (2.8.1)
@@ -126,7 +126,7 @@ GEM
126
126
  timeout
127
127
  net-smtp (0.5.0)
128
128
  net-protocol
129
- nio4r (2.7.3)
129
+ nio4r (2.7.4)
130
130
  nokogiri (1.16.7)
131
131
  mini_portile2 (~> 2.8.2)
132
132
  racc (~> 1.4)
@@ -140,20 +140,20 @@ GEM
140
140
  rack (2.2.10)
141
141
  rack-test (2.1.0)
142
142
  rack (>= 1.3)
143
- rails (7.0.8.5)
144
- actioncable (= 7.0.8.5)
145
- actionmailbox (= 7.0.8.5)
146
- actionmailer (= 7.0.8.5)
147
- actionpack (= 7.0.8.5)
148
- actiontext (= 7.0.8.5)
149
- actionview (= 7.0.8.5)
150
- activejob (= 7.0.8.5)
151
- activemodel (= 7.0.8.5)
152
- activerecord (= 7.0.8.5)
153
- activestorage (= 7.0.8.5)
154
- activesupport (= 7.0.8.5)
143
+ rails (7.0.8.6)
144
+ actioncable (= 7.0.8.6)
145
+ actionmailbox (= 7.0.8.6)
146
+ actionmailer (= 7.0.8.6)
147
+ actionpack (= 7.0.8.6)
148
+ actiontext (= 7.0.8.6)
149
+ actionview (= 7.0.8.6)
150
+ activejob (= 7.0.8.6)
151
+ activemodel (= 7.0.8.6)
152
+ activerecord (= 7.0.8.6)
153
+ activestorage (= 7.0.8.6)
154
+ activesupport (= 7.0.8.6)
155
155
  bundler (>= 1.15.0)
156
- railties (= 7.0.8.5)
156
+ railties (= 7.0.8.6)
157
157
  rails-dom-testing (2.2.0)
158
158
  activesupport (>= 5.0.0)
159
159
  minitest
@@ -161,9 +161,9 @@ GEM
161
161
  rails-html-sanitizer (1.6.0)
162
162
  loofah (~> 2.21)
163
163
  nokogiri (~> 1.14)
164
- railties (7.0.8.5)
165
- actionpack (= 7.0.8.5)
166
- activesupport (= 7.0.8.5)
164
+ railties (7.0.8.6)
165
+ actionpack (= 7.0.8.6)
166
+ activesupport (= 7.0.8.6)
167
167
  method_source
168
168
  rake (>= 12.2)
169
169
  thor (~> 1.0)
@@ -3,6 +3,7 @@
3
3
  require 'em-synchrony'
4
4
  require 'active_model'
5
5
  require 'active_record/errors'
6
+ require 'active_record/connection_adapters/mysql2_adapter'
6
7
  require 'active_record/connection_adapters/em_mysql2_adapter'
7
8
 
8
9
  module FiberedMysql2
@@ -69,12 +70,8 @@ module FiberedMysql2
69
70
  def new_client(config)
70
71
  Mysql2::EM::Client.new(config)
71
72
  rescue Mysql2::Error => error
72
- if error.error_number == ConnectionAdapters::Mysql2Adapter::ER_BAD_DB_ERROR
73
- raise ActiveRecord::NoDatabaseError.db_error(config[:database])
74
- elsif error.error_number == ConnectionAdapters::Mysql2Adapter::ER_ACCESS_DENIED_ERROR
75
- raise ActiveRecord::DatabaseConnectionError.username_error(config[:username])
76
- elsif [ConnectionAdapters::Mysql2Adapter::ER_CONN_HOST_ERROR, ConnectionAdapters::Mysql2Adapter::ER_UNKNOWN_HOST_ERROR].include?(error.error_number)
77
- raise ActiveRecord::DatabaseConnectionError.hostname_error(config[:host])
73
+ if error.error_number == 1049
74
+ raise ActiveRecord::NoDatabaseError.new, error.message
78
75
  else
79
76
  raise ActiveRecord::ConnectionNotEstablished, error.message
80
77
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module FiberedMysql2
4
- VERSION = "0.3.0"
4
+ VERSION = "0.3.1"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fibered_mysql2
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Invoca Development
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-10-23 00:00:00.000000000 Z
11
+ date: 2024-10-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: em-synchrony