-
Notifications
You must be signed in to change notification settings - Fork 7
/
.semgrep.yml
27 lines (27 loc) · 926 Bytes
/
.semgrep.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
rules:
- id: bibdata-no-rails-constant-in-marc-to-solr
message: The marc_to_solr directory does not autoload
the Rails constant, so indexing will probably
fail unexpectedly (even if the test suite passes).
severity: ERROR
languages:
- ruby
pattern: "Rails"
paths:
include:
- "marc_to_solr"
exclude:
- "spec/marc_to_solr"
- id: bibdata-do-not-expand-alma-user-find
message: "By default, Alma::User.find also retrieves
fees, requests, and loans. This is probably not
necessary for bibdata, and has caused the
Alma API to return errors in the past. Add
expand: '' to your call if you don't want these
expansions."
severity: WARNING
languages:
- ruby
patterns:
- pattern: "Alma::User.find(...)"
- pattern-not: "Alma::User.find(..., expand: '')"