gn_list_resolver 3.0.1.1 → 3.0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 7c042e74b667b59e965c894c4e86c6b743e31a89
4
- data.tar.gz: ef827961489aa0512591fdf5a23e3ecb9ac8e07f
3
+ metadata.gz: a6c2c5a779cccf17513a918c6facab6dab818a29
4
+ data.tar.gz: 14cf0ba4b222e83085e6dff086f396e07ebac4e6
5
5
  SHA512:
6
- metadata.gz: 3351e75cc0f45bed0d9924c0c970628bfb843d4c16e123d16d26a7609584069ac81ff80661c7e89aa3a1603150288e83e96ad8f34d6d995f1bbb5db1d3f19293
7
- data.tar.gz: 44d14f9feeafd840d0de88fc0a6ca5a5af98daee2740d5799fc0d932431918f75090243c473198b01932246c079cd58818097fe343d0c24bc032dfff24ab3493
6
+ metadata.gz: 78a041309b65af86db3271c9365dd77b70c86736ef6bc8ff970908438e7898896b3d9d06e5a57f3bb18b1c584dc7300465be906aae209bc090f3b0f4e2371273
7
+ data.tar.gz: 532058f4f440102b966127507c38a619a607cf95b9e2f7d31b9aa42873c19fa9a20d8a31da4ebd113684ae66d5d01663382f89d6ad6a3391d82810ae8d207f2d
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # ``gn_list_resolver`` CHANGELOG
2
2
 
3
+ ## 3.0.1.2
4
+
5
+ * @dimus - normalize matches to correspond go `gn_crossmap` ones
6
+
3
7
  ## 3.0.1.1
4
8
 
5
9
  * @dimus - refactoring, GnListResolver.run returns stats
@@ -7,4 +7,13 @@ module GnListResolver
7
7
  MATCH_TYPE_EMPTY = "EmptyMatch"
8
8
  RESOLVER_URL = ENV["GN_RESOLVER_URL"] ||
9
9
  "http://index-api.globalnames.org/api/graphql"
10
+ MATCH_TYPES = {
11
+ EmptyMatch: "No match",
12
+ ExactNameMatchByUUID: "Exact string match",
13
+ ExactCanonicalNameMatchByUUID: "Canonical form exact match",
14
+ FuzzyCanonicalMatch: "Canonical form fuzzy match",
15
+ ExactPartialMatch: "Partial canonical form match",
16
+ FuzzyPartialMatch: "Partial canonical form fuzzy match",
17
+ ExactMatchPartialByGenus: "Genus part match"
18
+ }.freeze
10
19
  end
@@ -50,7 +50,7 @@ module GnListResolver
50
50
  else
51
51
  match_type_min.match_type.kind
52
52
  end
53
- @stats.stats[:matches][match_type_value] += 1
53
+ @stats.stats[:matches][MATCH_TYPES[match_type_value.to_sym]] += 1
54
54
  @stats.stats[:resolved_records] += 1
55
55
  end
56
56
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  # Namespace module for crossmapping checklists to GN sources
4
4
  module GnListResolver
5
- VERSION = "3.0.1.1"
5
+ VERSION = "3.0.1.2"
6
6
 
7
7
  def self.version
8
8
  VERSION
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gn_list_resolver
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.1.1
4
+ version: 3.0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dmitry Mozzherin
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2017-07-23 00:00:00.000000000 Z
12
+ date: 2017-07-24 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: trollop