bel 0.4.1 → 0.4.2

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
  SHA1:
3
- metadata.gz: 1b8255ab8d0f64149d63bba68dfc581972af8ff5
4
- data.tar.gz: 71e13753d0f09de8f3a09d5b1a069400859e3ca4
3
+ metadata.gz: ded9890f8830061f79279b34c1930c6ffbab6e7f
4
+ data.tar.gz: 53bacbe8c477066ecdf0aff33005b98ccc6e9cc6
5
5
  SHA512:
6
- metadata.gz: 9c516ed72a14dcb7f4f7f30d880a938e5c2712cdb651eb71c85c2f70e1f2927e62541c19c564ae22a96e639d95a4e9adb01b45a6b8f55d2604c87251d5260ed3
7
- data.tar.gz: 459e40f9843c66830eae53bc499534221a0bcd4785cf85211bed21a836e5ba722f3ba1fe8b7d27754f852b44bf68d17c776971f15a0f43127472e1242c9aac25
6
+ metadata.gz: 3936bfbc725ce2b0178eaaa69f7f33eee0cc5436a1b249218d19c3a4e9ce8fb269e96fdc8c4a6c2380904b57dd4f4eaf4ec79eec198f3441339a1bc8f7f6753d
7
+ data.tar.gz: c7815b3f40a25219a712579169e409f097ea16285a78798b5d72236d51d1175ca9cb97fa2c249a197e400806dcdf88350b359e6aac2b192125fbea3ced9378ad
data/CHANGELOG.md CHANGED
@@ -3,6 +3,11 @@ All notable changes to bel.rb will be documented in this file. The curated log b
3
3
 
4
4
  This project adheres to [Semantic Versioning](http://semver.org/).
5
5
 
6
+ ## [0.4.2][0.4.2] - 2015-12-21
7
+ ### Fixed
8
+ - [Regression] Failure to run BEL upgrade command; yields name error ([Issue #90][90]).
9
+ - [Regression] Incorrect namespace concept URI when converting Term to RDF ([Issue #91][91]).
10
+
6
11
  ## [0.4.1][0.4.1] - 2015-12-17
7
12
  ### Added
8
13
  - Updated `find` API of `BEL::Resource::Namespaces` and `BEL::Resource::Namespace` to find by string representing a URI.
@@ -57,6 +62,7 @@ This project adheres to [Semantic Versioning](http://semver.org/).
57
62
  ### Added
58
63
  - Development gem dependencies (i.e. byebug, pry, pry-byebug) for debugging.
59
64
 
65
+ [0.4.2]: https://github.com/OpenBEL/bel.rb/compare/0.4.1...0.4.2
60
66
  [0.4.1]: https://github.com/OpenBEL/bel.rb/compare/0.4.0...0.4.1
61
67
  [0.4.0]: https://github.com/OpenBEL/bel.rb/compare/0.3.3...0.4.0
62
68
  [0.3.2]: https://github.com/OpenBEL/bel.rb/compare/0.3.1...0.3.2
@@ -73,5 +79,7 @@ This project adheres to [Semantic Versioning](http://semver.org/).
73
79
  [68]: https://github.com/OpenBEL/bel.rb/issues/68
74
80
  [82]: https://github.com/OpenBEL/bel.rb/issues/82
75
81
  [86]: https://github.com/OpenBEL/bel.rb/pull/86
82
+ [90]: https://github.com/OpenBEL/bel.rb/issues/90
83
+ [91]: https://github.com/OpenBEL/bel.rb/issues/91
76
84
  [20150611]: http://resource.belframework.org/belframework/20150611/
77
85
  [RDF.rb]: https://github.com/ruby-rdf/rdf
data/bin/bel_upgrade.rb CHANGED
@@ -106,7 +106,7 @@ class Main
106
106
  BEL::Script.parse(content) do |obj|
107
107
  # redefine namespace based on change log's `redefine` blocik
108
108
  # use 'namespaces' block, if available
109
- if obj.is_a? NamespaceDefinition
109
+ if obj.is_a? BEL::Namespace::NamespaceDefinition
110
110
  if @change_log.has_key? 'redefine'
111
111
  redefine = @change_log['redefine']['namespaces']
112
112
  if not redefine
@@ -116,7 +116,7 @@ class Main
116
116
  entry = redefine[obj.prefix.to_s]
117
117
  new_keyword = entry['new_keyword'].to_sym
118
118
  new_url = entry['new_url']
119
- obj = NamespaceDefinition.new(new_keyword, new_url)
119
+ obj = BEL::Namespace::NamespaceDefinition.new(new_keyword, new_url)
120
120
  end
121
121
  end
122
122
 
@@ -128,21 +128,21 @@ class Main
128
128
  end
129
129
 
130
130
  # update annotation definitions
131
- if obj.is_a? AnnotationDefinition and obj.type.eql? :url
131
+ if obj.is_a? BEL::Language::AnnotationDefinition and obj.type.eql? :url
132
132
  if @redefine_annotations
133
133
  old_url = obj.value
134
134
  if @annotation_url_map.has_key? old_url.to_s
135
135
  kw = obj.prefix
136
136
  new_url = @annotation_url_map[old_url]['new_url']
137
137
  prefix = @annotation_url_map[old_url]['prefix']
138
- obj = AnnotationDefinition.new(:url, kw, new_url)
138
+ obj = BEL::Language::AnnotationDefinition.new(:url, kw, new_url)
139
139
  @annotation_keyword_map[kw] = prefix # map bel doc annotation kw to set of changelog prefixes
140
140
  end
141
141
  end
142
142
  end
143
143
 
144
144
  # evidence always needs quoting; backwards-compatibility
145
- if obj.is_a? Annotation
145
+ if obj.is_a? BEL::Language::Annotation
146
146
  if obj.name == 'Evidence'
147
147
  ev = obj.to_s
148
148
  ev.gsub!(EvidenceMatcher, 'SET Evidence = "\1"')
@@ -207,7 +207,7 @@ class Main
207
207
  if redefinition
208
208
  new_prefix = redefinition['new_keyword']
209
209
  new_url = redefinition['new_url']
210
- obj.ns = NamespaceDefinition.new(new_prefix, new_url)
210
+ obj.ns = BEL::Namespace::NamespaceDefinition.new(new_prefix, new_url)
211
211
 
212
212
  # ...and replace value using new namespace prefix
213
213
  replacements = @change_log[new_prefix]
data/lib/bel/namespace.rb CHANGED
@@ -42,11 +42,11 @@ module BEL
42
42
  ],
43
43
  GOBP: [
44
44
  LATEST_PREFIX + 'namespace/go-biological-process.belns',
45
- 'http://www.openbel.org/bel/namespace/go-biological-processes'
45
+ 'http://www.openbel.org/bel/namespace/go-biological-process'
46
46
  ],
47
47
  GOBPID: [
48
48
  LATEST_PREFIX + 'namespace/go-biological-process-ids.belns',
49
- 'http://www.openbel.org/bel/namespace/go'
49
+ 'http://www.openbel.org/bel/namespace/go-biological-process'
50
50
  ],
51
51
  GOCC: [
52
52
  LATEST_PREFIX + 'namespace/go-cellular-component.belns',
@@ -68,6 +68,14 @@ module BEL
68
68
  LATEST_PREFIX + 'namespace/mesh-cellular-structures-ids.belns',
69
69
  'http://www.openbel.org/bel/namespace/mesh-cellular-structures'
70
70
  ],
71
+ MECHC: [
72
+ LATEST_PREFIX + 'namespace/mesh-chemicals.belns',
73
+ 'http://www.openbel.org/bel/namespace/mesh-chemicals'
74
+ ],
75
+ MECHCID: [
76
+ LATEST_PREFIX + 'namespace/mesh-chemicals-ids.belns',
77
+ 'http://www.openbel.org/bel/namespace/mesh-chemicals'
78
+ ],
71
79
  MESHD: [
72
80
  LATEST_PREFIX + 'namespace/mesh-diseases.belns',
73
81
  'http://www.openbel.org/bel/namespace/mesh-diseases',
@@ -114,7 +122,7 @@ module BEL
114
122
  ],
115
123
  SPID: [
116
124
  LATEST_PREFIX + 'namespace/swissprot-ids.belns',
117
- 'http://www.openbel.org/bel/namespace/swissprot-ids'
125
+ 'http://www.openbel.org/bel/namespace/swissprot'
118
126
  ]
119
127
  }
120
128
 
@@ -154,7 +154,7 @@ module BEL::Translator::Plugins
154
154
  @arguments.find_all{ |x|
155
155
  x.is_a? ::BEL::Model::Parameter and x.ns != nil
156
156
  }.each do |param|
157
- concept_uri = param.ns.to_uri + param.value.to_s
157
+ concept_uri = "#{param.ns.to_uri}/#{param.value}"
158
158
  statements << ::RDF::Statement.new(uri, BEL::RDF::BELV.hasConcept, BEL::RDF::RDF::URI(URI.encode(concept_uri)), :graph_name => graph_name)
159
159
  end
160
160
 
data/lib/bel/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module BEL
2
- VERSION = '0.4.1'
2
+ VERSION = '0.4.2'
3
3
  end
metadata CHANGED
@@ -1,34 +1,34 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bel
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.1
4
+ version: 0.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Anthony Bargnesi
8
8
  - Natalie Catlett
9
9
  - Nick Bargnesi
10
10
  - William Hayes
11
- autorequire:
11
+ autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2015-12-17 00:00:00.000000000 Z
14
+ date: 2015-12-21 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
+ name: ffi
17
18
  requirement: !ruby/object:Gem::Requirement
18
19
  requirements:
19
20
  - - '='
20
21
  - !ruby/object:Gem::Version
21
22
  version: 1.9.8
22
- name: ffi
23
- prerelease: false
24
23
  type: :runtime
24
+ prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
26
26
  requirements:
27
27
  - - '='
28
28
  - !ruby/object:Gem::Version
29
29
  version: 1.9.8
30
- description: " The BEL gem allows the reading, writing, and processing of BEL (Biological\
31
- \ Expression Language) with a natural DSL. "
30
+ description: " The BEL gem allows the reading, writing, and processing of BEL (Biological
31
+ Expression Language) with a natural DSL. "
32
32
  email:
33
33
  - abargnesi@selventa.com
34
34
  - ncatlett@selventa.com
@@ -167,7 +167,7 @@ homepage: https://github.com/OpenBEL/bel.rb
167
167
  licenses:
168
168
  - Apache-2.0
169
169
  metadata: {}
170
- post_install_message:
170
+ post_install_message:
171
171
  rdoc_options:
172
172
  - "--title"
173
173
  - BEL Ruby Documentation
@@ -201,10 +201,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
201
201
  - !ruby/object:Gem::Version
202
202
  version: '0'
203
203
  requirements: []
204
- rubyforge_project:
205
- rubygems_version: 2.4.8
206
- signing_key:
204
+ rubyforge_project:
205
+ rubygems_version: 2.4.5.1
206
+ signing_key:
207
207
  specification_version: 4
208
208
  summary: Process BEL with ruby.
209
209
  test_files: []
210
- has_rdoc:
210
+ has_rdoc: