prosopite 1.0.7 → 1.0.8

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: 77b0146b180d4bf96cf36dc03c4579f44b7e8aff4693742bfcce6321057027b2
4
- data.tar.gz: 8203dc334b5787907b5d1d25a29927b228f51c62d3814edfacd22424f0a9d20f
3
+ metadata.gz: 1af17b69a330a3d3f6671044a52767af5f93c6245c24f8f690320bf70b863b5f
4
+ data.tar.gz: 3abb664fad375de93c92f909e42bcc68d89287271b9be57d85a1c1f9cb561cba
5
5
  SHA512:
6
- metadata.gz: 07ec42c20dc33120d6ae393f9272aa9bce89d0c18e29544ddbf9d6da02688b110d85700b4d9913ca1abcb6468f0eb57ba1259ff7990ec80f2600e02321845f63
7
- data.tar.gz: c8194ba025357e7afba769c163fad93cc2dfc1adf489d497acc9c94efdd5f50949b724517e8d9032b1e7267e3c4075c51ed67e4a6a63de5139ed284b7277fb51
6
+ metadata.gz: acdecfb19aff6229c9ec15dd62794b786caf21e30a96d5c8a0038412b1805938217f70380d7501054721f8a716ff40c883b12d21e888befcf434f6a503d2cf99
7
+ data.tar.gz: 5d71d8b945b92e3db0a3f9993217ab85a363b5e259134f95be03bb214e8ffdb9bd9e814983104571e698dcb1863f9bb9e3ec89bf0246ebdfbc8d15c75fa9a3b9
@@ -4,7 +4,7 @@ jobs:
4
4
  test:
5
5
  strategy:
6
6
  matrix:
7
- ruby: [2.5, 2.6, 2.7, '3.0', head]
7
+ ruby: [2.5, 2.6, 2.7, '3.0', 3.1, head]
8
8
  runs-on: ubuntu-latest
9
9
  steps:
10
10
  - uses: actions/checkout@v2
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- prosopite (1.0.7)
4
+ prosopite (1.0.8)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
data/README.md CHANGED
@@ -128,7 +128,7 @@ Prosopite auto-detection can be enabled on all controllers:
128
128
  class ApplicationController < ActionController::Base
129
129
  unless Rails.env.production?
130
130
  around_action :n_plus_one_detection
131
-
131
+
132
132
  def n_plus_one_detection
133
133
  Prosopite.scan
134
134
  yield
@@ -179,10 +179,10 @@ WARNING: scan/finish should run before/after **each** test and NOT before/after
179
179
 
180
180
  ## Allow list
181
181
 
182
- Ignore notifications for call stacks containing one or more substrings:
182
+ Ignore notifications for call stacks containing one or more substrings / regex:
183
183
 
184
184
  ```ruby
185
- Prosopite.allow_stack_paths = ['substring_in_call_stack']
185
+ Prosopite.allow_stack_paths = ['substring_in_call_stack', /regex/]
186
186
  ```
187
187
 
188
188
  Ignore notifications matching a specific SQL query:
@@ -201,7 +201,7 @@ Prosopite.scan
201
201
  Prosopite.finish
202
202
  ```
203
203
 
204
- or
204
+ or
205
205
 
206
206
  ```ruby
207
207
  Prosopite.scan do
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Prosopite
4
- VERSION = "1.0.7"
4
+ VERSION = "1.0.8"
5
5
  end
data/lib/prosopite.rb CHANGED
@@ -83,7 +83,7 @@ module Prosopite
83
83
 
84
84
  kaller = tc[:prosopite_query_caller][location_key]
85
85
  allow_list = (@allow_stack_paths + DEFAULT_ALLOW_LIST)
86
- is_allowed = kaller.any? { |f| allow_list.any? { |s| f.include?(s) } }
86
+ is_allowed = kaller.any? { |f| allow_list.any? { |s| f.match?(s) } }
87
87
 
88
88
  unless is_allowed
89
89
  queries = tc[:prosopite_query_holder][location_key]
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: prosopite
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.7
4
+ version: 1.0.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mpampis Kostas
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-01-20 00:00:00.000000000 Z
11
+ date: 2022-02-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: pry