schemata-dea 0.0.1.beta5 → 0.0.1.beta6

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,12 +1,18 @@
1
1
  module Schemata
2
2
  class DecodeError < StandardError; end
3
3
  class EncodeError < StandardError; end
4
- class UpdateAttributeError < StandardError; end
4
+ class SchemaDefinitionError < StandardError; end
5
+
6
+ class UpdateAttributeError < StandardError
7
+ def initialize(key, message)
8
+ super("#{key}: #{message}")
9
+ end
10
+ end
11
+
5
12
  class IncompatibleVersionError < DecodeError
6
13
  def initialize(msg_version, component_version)
7
14
  super("min message version #{msg_version} too high for component ver\
8
15
  sion #{component_version}")
9
16
  end
10
17
  end
11
- class SchemaDefinitionError < StandardError; end
12
18
  end
@@ -30,7 +30,7 @@ module Schemata
30
30
  begin
31
31
  field_schema.validate(field_value)
32
32
  rescue ::Membrane::SchemaValidationError => e
33
- raise Schemata::UpdateAttributeError.new(e.message)
33
+ raise Schemata::UpdateAttributeError.new(key, e.message)
34
34
  end
35
35
 
36
36
  @contents[key] = Schemata::HashCopyHelpers.deep_copy(field_value)
@@ -55,7 +55,7 @@ module Schemata
55
55
  begin
56
56
  field_schema.validate(field_value)
57
57
  rescue ::Membrane::SchemaValidationError => e
58
- raise Schemata::UpdateAttributeError.new(e.message)
58
+ raise Schemata::UpdateAttributeError.new(key, e.message)
59
59
  end
60
60
  @contents[key] = Schemata::HashCopyHelpers.deep_copy(field_value)
61
61
  field_value
@@ -1,5 +1,5 @@
1
1
  module Schemata
2
2
  module DEA
3
- VERSION = "0.0.1.beta5"
3
+ VERSION = "0.0.1.beta6"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: schemata-dea
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1.beta5
4
+ version: 0.0.1.beta6
5
5
  prerelease: 6
6
6
  platform: ruby
7
7
  authors: