stepper_motor 0.1.9 → 0.1.10
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 +4 -4
- data/CHANGELOG.md +10 -6
- data/README.md +2 -4
- data/lib/generators/stepper_motor_migration_004.rb.erb +2 -2
- data/lib/stepper_motor/version.rb +1 -1
- data/manual/MANUAL.md +0 -11
- data/rbi/stepper_motor.rbi +1 -1
- data/test/dummy/db/migrate/{20250525132526_stepper_motor_migration_004.rb → 20250528141038_stepper_motor_migration_004.rb} +2 -2
- data/test/dummy/db/schema.rb +1 -1
- metadata +7 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 649ad16d1e0831632a111b96f7435d66e2f601f6c301631252420876f6d2045a
|
4
|
+
data.tar.gz: 6f09feace77d276184ad9e43e466c11aaf2b3df9fa295d11cf934d1ae719742f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 265c265164a0330f2de6f75012146dbe179147d7b808c2003b00aced6f9599709648384104fb8cd3a3f41d3211320e871dcc29b34f0faba07867296c8beda561
|
7
|
+
data.tar.gz: 8275f9be10d01974d1aa9541d5d3784a056785c9e4412dbec74edbd95cfd4aa9fffad4d9fa08fc60f4621e75d81fc90af4e2893c8a944c7d4a6d399ab5e069d5
|
data/CHANGELOG.md
CHANGED
@@ -1,16 +1,21 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
## [0.1.10] - 2025-05-28
|
4
|
+
|
5
|
+
- Remove `algorithm: :concurrently` from migrations. If a user needs to conform with strong_migrations
|
6
|
+
they can always edit the migration themselves.
|
7
|
+
|
3
8
|
## [0.1.9] - 2025-05-25
|
4
9
|
|
5
10
|
- Repair bodged migration from the previous release
|
6
11
|
|
7
12
|
## [0.1.8] - 2025-05-25
|
8
13
|
|
9
|
-
- Add ability to pause and resume journeys (
|
10
|
-
- Add basic exception rescue during steps (
|
11
|
-
- Add idempotency keys when performing steps (
|
12
|
-
- Add support for blockless step definitions (
|
13
|
-
- Migrate from RSpec to Minitest (
|
14
|
+
- Add ability to pause and resume journeys (https://github.com/stepper-motor/stepper_motor/pull/24)
|
15
|
+
- Add basic exception rescue during steps (https://github.com/stepper-motor/stepper_motor/pull/23)
|
16
|
+
- Add idempotency keys when performing steps (https://github.com/stepper-motor/stepper_motor/pull/21)
|
17
|
+
- Add support for blockless step definitions (https://github.com/stepper-motor/stepper_motor/pull/22)
|
18
|
+
- Migrate from RSpec to Minitest (https://github.com/stepper-motor/stepper_motor/pull/19)
|
14
19
|
- Add Rake task for recovery
|
15
20
|
- Add proper Rails engine tests
|
16
21
|
- Improve test organization and coverage
|
@@ -41,7 +46,6 @@
|
|
41
46
|
- Refactor PerformStepJob to use Journey class in job arguments
|
42
47
|
- Remove GlobalID dependency
|
43
48
|
- Add ability to resolve Journey from base class using `find()`
|
44
|
-
- Prepare groundwork for future improvements (#12)
|
45
49
|
|
46
50
|
## [0.1.4] - 2025-03-11
|
47
51
|
|
data/README.md
CHANGED
@@ -24,7 +24,7 @@ end
|
|
24
24
|
SignupJourney.create!(hero: current_user)
|
25
25
|
```
|
26
26
|
|
27
|
-
Want to know more? Dive into the [manual](
|
27
|
+
Want to know more? Dive into the [manual](/manual/MANUAL.md) we provide.
|
28
28
|
|
29
29
|
## Installation
|
30
30
|
|
@@ -47,9 +47,7 @@ Starting with versions 0.2.x and up, stepper_motor will make the best possible e
|
|
47
47
|
|
48
48
|
## Development
|
49
49
|
|
50
|
-
After checking out the repo, run `
|
51
|
-
|
52
|
-
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
50
|
+
After checking out the repo, run `bundle` to install dependencies. The development process from there on is like any other gem.
|
53
51
|
|
54
52
|
## Is it any good?
|
55
53
|
|
@@ -7,7 +7,7 @@ class StepperMotorMigration004 < ActiveRecord::Migration[<%= migration_version %
|
|
7
7
|
name: :idx_journeys_one_per_hero_with_paused
|
8
8
|
|
9
9
|
# Remove old indexes that only include 'ready' state
|
10
|
-
remove_index :stepper_motor_journeys, [:type, :hero_id, :hero_type], name: :one_per_hero_index, where: "allow_multiple = '0' AND state IN ('ready', 'performing')"
|
10
|
+
remove_index :stepper_motor_journeys, [:type, :hero_id, :hero_type], name: :one_per_hero_index, where: "allow_multiple = '0' AND state IN ('ready', 'performing')"
|
11
11
|
end
|
12
12
|
|
13
13
|
def down
|
@@ -19,6 +19,6 @@ class StepperMotorMigration004 < ActiveRecord::Migration[<%= migration_version %
|
|
19
19
|
name: :one_per_hero_index
|
20
20
|
|
21
21
|
# Remove new indexes
|
22
|
-
remove_index :stepper_motor_journeys, name: :idx_journeys_one_per_hero_with_paused
|
22
|
+
remove_index :stepper_motor_journeys, name: :idx_journeys_one_per_hero_with_paused
|
23
23
|
end
|
24
24
|
end
|
data/manual/MANUAL.md
CHANGED
@@ -1,14 +1,3 @@
|
|
1
|
-
|
2
|
-
## Installation
|
3
|
-
|
4
|
-
Add the gem to the application's Gemfile, and then generate and run the migration
|
5
|
-
|
6
|
-
$ bundle add stepper_motor
|
7
|
-
$ bundle install
|
8
|
-
$ bin/rails g stepper_motor:install --uuid # Pass "uuid" if you are using UUID for your primary and foreign keys
|
9
|
-
$ bin/rails db:migrate
|
10
|
-
|
11
|
-
|
12
1
|
## Intro
|
13
2
|
|
14
3
|
`stepper_motor` solves a real, tangible problem in Rails apps - tracking activities over long periods of time. It does so in a durable, reentrant and consistent manner, utilizing the guarantees provided by your relational database you already have.
|
data/rbi/stepper_motor.rbi
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
# StepperMotor is a module for building multi-step flows where steps are sequential and only
|
3
3
|
# ever progress forward. The building block of StepperMotor is StepperMotor::Journey
|
4
4
|
module StepperMotor
|
5
|
-
VERSION = T.let("0.1.
|
5
|
+
VERSION = T.let("0.1.10", T.untyped)
|
6
6
|
|
7
7
|
class Error < StandardError
|
8
8
|
end
|
@@ -7,7 +7,7 @@ class StepperMotorMigration004 < ActiveRecord::Migration[7.2]
|
|
7
7
|
name: :idx_journeys_one_per_hero_with_paused
|
8
8
|
|
9
9
|
# Remove old indexes that only include 'ready' state
|
10
|
-
remove_index :stepper_motor_journeys, [:type, :hero_id, :hero_type], name: :one_per_hero_index, where: "allow_multiple = '0' AND state IN ('ready', 'performing')"
|
10
|
+
remove_index :stepper_motor_journeys, [:type, :hero_id, :hero_type], name: :one_per_hero_index, where: "allow_multiple = '0' AND state IN ('ready', 'performing')"
|
11
11
|
end
|
12
12
|
|
13
13
|
def down
|
@@ -19,6 +19,6 @@ class StepperMotorMigration004 < ActiveRecord::Migration[7.2]
|
|
19
19
|
name: :one_per_hero_index
|
20
20
|
|
21
21
|
# Remove new indexes
|
22
|
-
remove_index :stepper_motor_journeys, name: :idx_journeys_one_per_hero_with_paused
|
22
|
+
remove_index :stepper_motor_journeys, name: :idx_journeys_one_per_hero_with_paused
|
23
23
|
end
|
24
24
|
end
|
data/test/dummy/db/schema.rb
CHANGED
@@ -10,7 +10,7 @@
|
|
10
10
|
#
|
11
11
|
# It's strongly recommended that you check this file into your version control system.
|
12
12
|
|
13
|
-
ActiveRecord::Schema[7.2].define(version:
|
13
|
+
ActiveRecord::Schema[7.2].define(version: 2025_05_28_141038) do
|
14
14
|
create_table "stepper_motor_journeys", force: :cascade do |t|
|
15
15
|
t.string "type", null: false
|
16
16
|
t.string "state", default: "ready"
|
metadata
CHANGED
@@ -1,13 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: stepper_motor
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.10
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Julik Tarkhanov
|
8
|
+
autorequire:
|
8
9
|
bindir: exe
|
9
10
|
cert_chain: []
|
10
|
-
date: 2025-05-
|
11
|
+
date: 2025-05-28 00:00:00.000000000 Z
|
11
12
|
dependencies:
|
12
13
|
- !ruby/object:Gem::Dependency
|
13
14
|
name: activerecord
|
@@ -253,7 +254,7 @@ files:
|
|
253
254
|
- test/dummy/db/migrate/20250525132523_stepper_motor_migration_001.rb
|
254
255
|
- test/dummy/db/migrate/20250525132524_stepper_motor_migration_002.rb
|
255
256
|
- test/dummy/db/migrate/20250525132525_stepper_motor_migration_003.rb
|
256
|
-
- test/dummy/db/migrate/
|
257
|
+
- test/dummy/db/migrate/20250528141038_stepper_motor_migration_004.rb
|
257
258
|
- test/dummy/db/schema.rb
|
258
259
|
- test/dummy/public/400.html
|
259
260
|
- test/dummy/public/404.html
|
@@ -284,6 +285,7 @@ metadata:
|
|
284
285
|
homepage_uri: https://steppermotor.dev
|
285
286
|
source_code_uri: https://github.com/stepper-motor/stepper_motor
|
286
287
|
changelog_uri: https://github.com/stepper-motor/stepper_motor/blob/main/CHANGELOG.md
|
288
|
+
post_install_message:
|
287
289
|
rdoc_options: []
|
288
290
|
require_paths:
|
289
291
|
- lib
|
@@ -298,7 +300,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
298
300
|
- !ruby/object:Gem::Version
|
299
301
|
version: '0'
|
300
302
|
requirements: []
|
301
|
-
rubygems_version: 3.
|
303
|
+
rubygems_version: 3.4.10
|
304
|
+
signing_key:
|
302
305
|
specification_version: 4
|
303
306
|
summary: Effortless step workflows that embed nicely inside Rails
|
304
307
|
test_files: []
|