prosopite 0.2.1 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -0
- data/Gemfile.lock +2 -2
- data/README.md +6 -0
- data/lib/prosopite.rb +6 -1
- data/lib/prosopite/version.rb +1 -1
- data/prosopite.gemspec +0 -2
- metadata +2 -16
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3df6a0299972911e48ea44330995864e2cd2191ec66c199296ba324a5fa8e639
|
4
|
+
data.tar.gz: 4f9ee347a8cf52fd742ee66586c7e4b601c8436a4bcabe1b1afdef5e09293f44
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 668bc7e58bcabd77231adc831054d56ca572e1e9857f87736d1fd06048c1eeaac9c0c0ab970c6ed6f8ce70670ae51277c3c4f56012d0ec61240c0e728c1f3795
|
7
|
+
data.tar.gz: '0341920f4f1beddc2b9c46553f9284724ecddfe50f30579a7cc9627c93fdf2d3c714bb57fd453dd7a4783a86951b9dd2cb0a79e721189bce3b89eda0c119c8bf'
|
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,8 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
prosopite (0.2.
|
5
|
-
pg_query (~> 1.3)
|
4
|
+
prosopite (0.2.1)
|
6
5
|
|
7
6
|
GEM
|
8
7
|
remote: https://rubygems.org/
|
@@ -44,6 +43,7 @@ DEPENDENCIES
|
|
44
43
|
activerecord
|
45
44
|
factory_bot
|
46
45
|
minitest
|
46
|
+
pg_query
|
47
47
|
prosopite!
|
48
48
|
pry
|
49
49
|
rake (~> 13.0)
|
data/README.md
CHANGED
data/lib/prosopite.rb
CHANGED
@@ -1,4 +1,3 @@
|
|
1
|
-
require 'pg_query'
|
2
1
|
|
3
2
|
module Prosopite
|
4
3
|
class NPlusOneQueriesError < StandardError; end
|
@@ -71,6 +70,12 @@ module Prosopite
|
|
71
70
|
if ActiveRecord::Base.connection.adapter_name.downcase.include?('mysql')
|
72
71
|
mysql_fingerprint(query)
|
73
72
|
else
|
73
|
+
begin
|
74
|
+
require 'pg_query'
|
75
|
+
rescue LoadError => e
|
76
|
+
msg = "Could not load the 'pg_query' gem. Add `gem 'pg_query'` to your Gemfile"
|
77
|
+
raise LoadError, msg, e.backtrace
|
78
|
+
end
|
74
79
|
PgQuery.fingerprint(query)
|
75
80
|
end
|
76
81
|
end
|
data/lib/prosopite/version.rb
CHANGED
data/prosopite.gemspec
CHANGED
@@ -24,8 +24,6 @@ Gem::Specification.new do |spec|
|
|
24
24
|
end
|
25
25
|
spec.require_paths = ["lib"]
|
26
26
|
|
27
|
-
spec.add_runtime_dependency 'pg_query', '~> 1.3'
|
28
|
-
|
29
27
|
spec.add_development_dependency "pry"
|
30
28
|
spec.add_development_dependency "minitest"
|
31
29
|
spec.add_development_dependency "factory_bot"
|
metadata
CHANGED
@@ -1,29 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: prosopite
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 1.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mpampis Kostas
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-03-
|
11
|
+
date: 2021-03-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
|
-
- !ruby/object:Gem::Dependency
|
14
|
-
name: pg_query
|
15
|
-
requirement: !ruby/object:Gem::Requirement
|
16
|
-
requirements:
|
17
|
-
- - "~>"
|
18
|
-
- !ruby/object:Gem::Version
|
19
|
-
version: '1.3'
|
20
|
-
type: :runtime
|
21
|
-
prerelease: false
|
22
|
-
version_requirements: !ruby/object:Gem::Requirement
|
23
|
-
requirements:
|
24
|
-
- - "~>"
|
25
|
-
- !ruby/object:Gem::Version
|
26
|
-
version: '1.3'
|
27
13
|
- !ruby/object:Gem::Dependency
|
28
14
|
name: pry
|
29
15
|
requirement: !ruby/object:Gem::Requirement
|