statesman 4.1.0 → 4.1.1

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
- SHA256:
3
- metadata.gz: 4fb61c0976e4be7109c74119ce4a04bec415b463295a2a72adddedde288012bc
4
- data.tar.gz: 895b55c0827be27cccde416b3c71cc375f2e2f0c7fa847ef858f40e58ddfbf4b
2
+ SHA1:
3
+ metadata.gz: 7bcb79a19d0e00628ae28cc7dbfb5f97977f3aa1
4
+ data.tar.gz: b085866e8bb72e8b48eec5b08e5243553dcf6264
5
5
  SHA512:
6
- metadata.gz: 3a12259539822ebb79e79a76f47275636da60d799b28b8c436cd9ddfdcc1e8d459897867816832fe524263b1f5c536db78e3617609e77054d43d872c6286a652
7
- data.tar.gz: a1963915c8231d6c8ed037733a652e581f1efcf6d8ce76e535b8f50fa81e8a288a3723bb2974a2178cd11b2b0c6502fe6b49b216b2c9f82e1846cbdfb1cc6ada
6
+ metadata.gz: 8132a5e0e581c1b9fa6e6858fc85b7b2c35a703e7ce092c0841e15d63d09984ccc6e4df46aaa6eda319f0842266992a575a90195061b24e0bd209e929d2eaef5
7
+ data.tar.gz: d2afbe9e9fb2aec84cffa7719aceaf71959a48b04924427374cb056d3a91c484e11ffab3bd4a02520217817c2d3ec728904073ad38c714af6b1ace774e661c45
@@ -142,7 +142,7 @@ jobs:
142
142
  docker:
143
143
  - image: circleci/ruby:2.6.2-node
144
144
  environment:
145
- - RAILS_VERSION=6.0.0.beta3
145
+ - RAILS_VERSION=6.0.0.rc1
146
146
  - DATABASE_DEPENDENCY_PORT=27017
147
147
  - image: circleci/mongo:3
148
148
  steps: *steps
@@ -150,7 +150,7 @@ jobs:
150
150
  docker:
151
151
  - image: circleci/ruby:2.6.2-node
152
152
  environment:
153
- - RAILS_VERSION=6.0.0.beta3
153
+ - RAILS_VERSION=6.0.0.rc1
154
154
  - DATABASE_URL=mysql2://root@127.0.0.1/statesman_test
155
155
  - EXCLUDE_MONGOID=true
156
156
  - DATABASE_DEPENDENCY_PORT=3306
@@ -165,7 +165,7 @@ jobs:
165
165
  docker:
166
166
  - image: circleci/ruby:2.6.2-node
167
167
  environment:
168
- - RAILS_VERSION=6.0.0.beta3
168
+ - RAILS_VERSION=6.0.0.rc1
169
169
  - DATABASE_URL=postgres://postgres@localhost/statesman_test
170
170
  - EXCLUDE_MONGOID=true
171
171
  - DATABASE_DEPENDENCY_PORT=5432
@@ -1,3 +1,8 @@
1
+ ## v4.1.1, 6th July 2019
2
+
3
+ - Fix statesman index detection for indexes that start t-z [@hmarr](https://github.com/gocardless/statesman/pull/354)
4
+ - Correct access of metadata via `state_machine` [@glenpike](https://github.com/gocardless/statesman/pull/349)
5
+
1
6
  ## v4.1.0, 10 April 2019
2
7
 
3
8
  - Add better support for mysql (and others) in `transition_conflict_error?` [@greysteil](https://github.com/greysteil) (https://github.com/gocardless/statesman/pull/342)
data/README.md CHANGED
@@ -406,7 +406,7 @@ You could also use a calculated column or view in your database.
406
406
  Given a field `foo` that was stored in the metadata, you can access it like so:
407
407
 
408
408
  ```ruby
409
- model_instance.last_transition.metadata["foo"]
409
+ model_instance.state_machine.last_transition.metadata["foo"]
410
410
  ```
411
411
 
412
412
  #### Events
@@ -140,8 +140,10 @@ module Statesman
140
140
  select do |index|
141
141
  next unless index.unique
142
142
 
143
- index.columns.sort == [parent_join_foreign_key, "sort_key"] ||
144
- index.columns.sort == [parent_join_foreign_key, "most_recent"]
143
+ # We care about the columns used in the index, but not necessarily
144
+ # the order, which is why we sort both sides of the comparison here
145
+ index.columns.sort == [parent_join_foreign_key, "sort_key"].sort ||
146
+ index.columns.sort == [parent_join_foreign_key, "most_recent"].sort
145
147
  end
146
148
  end
147
149
 
@@ -1,3 +1,3 @@
1
1
  module Statesman
2
- VERSION = "4.1.0".freeze
2
+ VERSION = "4.1.1".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: statesman
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.1.0
4
+ version: 4.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - GoCardless
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-04-10 00:00:00.000000000 Z
11
+ date: 2019-07-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ammeter
@@ -298,7 +298,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
298
298
  - !ruby/object:Gem::Version
299
299
  version: '0'
300
300
  requirements: []
301
- rubygems_version: 3.0.1
301
+ rubyforge_project:
302
+ rubygems_version: 2.5.2.3
302
303
  signing_key:
303
304
  specification_version: 4
304
305
  summary: A statesman-like state machine library