alarmable 2.1.0 → 2.2.0

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
  SHA256:
3
- metadata.gz: d4c5fb3a2af50ea846e77391b001656aae22d3d42e03e4f69cacfd7b327e849d
4
- data.tar.gz: a4c351bd05b94b86e67be9facf8b70459ff6515ef97b8c82548d78ae1b3e9438
3
+ metadata.gz: 956ddc795de786546c175450bbefaa7a5e37129fee88188eaf349f4ca345eeea
4
+ data.tar.gz: ab6ec26509dea630f5dabb4f34153446cc3756d2be9f772eb199c2a7be73a905
5
5
  SHA512:
6
- metadata.gz: 48c45a04e459087749066905301acb1b915bf54e0c44d9c4dc6e0625f3392f7cfb35a8659f62ea66d2b30cced45950396a61c51183320e6669e77b7c895b84b5
7
- data.tar.gz: 33971096ba1d0a6df18fb82882e5b0c9cde69fd13fc96c34168795f1053c71fdc6b47508b9ab1814b27b4ab907fa1b6330ccf286a0af90b45c002536460ff2dd
6
+ metadata.gz: 4af5672f56a725fb3ebb9e5822f8a304c27f4a81993d1158fbd870714dbfe141a759973933fcf312bb2c45ac625d9b809e3f1670371b45fc4c69791e897e580a
7
+ data.tar.gz: 7ac47b411bd7036dbcf07ee7600c0f3d7859773ee3658f0446e1c8571c58518bf65e20f052e6608f2d78fbb6894a5a2528be98d80601b181fb1441c1a6a294ab
data/.rubocop.yml CHANGED
@@ -1,3 +1,7 @@
1
+ inherit_from:
2
+ - https://potpourri.hausgold.de/config/rubocop.yml
3
+ - https://potpourri.hausgold.de/config/rubocop-gem.yml
4
+
1
5
  plugins:
2
6
  - rubocop-rspec
3
7
  - rubocop-rails
@@ -5,9 +9,6 @@ plugins:
5
9
  Rails:
6
10
  Enabled: true
7
11
 
8
- Style/Documentation:
9
- Enabled: true
10
-
11
12
  AllCops:
12
13
  NewCops: enable
13
14
  SuggestExtensions: false
@@ -20,43 +21,12 @@ AllCops:
20
21
  - build/**/*
21
22
  - gemfiles/**/*
22
23
 
23
- Metrics/BlockLength:
24
- Exclude:
25
- - Rakefile
26
- - '*.gemspec'
27
- - spec/**/*.rb
28
- - '**/*.rake'
29
- - doc/**/*.rb
30
-
31
- # MFA is not yet enabled for our gems yet.
32
- Gemspec/RequireMFA:
33
- Enabled: false
34
-
35
- # Document all the things.
36
- Style/DocumentationMethod:
37
- Enabled: true
38
- RequireForNonPublicMethods: true
39
-
40
24
  # It's a deliberate idiom in RSpec.
41
25
  # See: https://github.com/bbatsov/rubocop/issues/4222
42
26
  Lint/AmbiguousBlockAssociation:
43
27
  Exclude:
44
28
  - "spec/**/*"
45
29
 
46
- # Because +expect_any_instance_of().to have_received()+ is not
47
- # supported with the +with(hash_including)+ matchers
48
- RSpec/MessageSpies:
49
- EnforcedStyle: receive
50
-
51
- # We stay with the original Ruby Style Guide recommendation.
52
- Layout/LineLength:
53
- Max: 80
54
-
55
- # Because nesting makes sense here to group the feature tests
56
- # more effective. This increases maintainability.
57
- RSpec/NestedGroups:
58
- Max: 4
59
-
60
30
  # Disable regular Rails spec paths.
61
31
  Rails/FilePath:
62
32
  Enabled: false
@@ -77,7 +47,3 @@ Rails/ApplicationJob:
77
47
  # so when first evaluated it won't change.
78
48
  RSpec/ExpectChange:
79
49
  Enabled: false
80
-
81
- # We highly depend on memoized helpers across the specs.
82
- RSpec/MultipleMemoizedHelpers:
83
- Enabled: false
data/CHANGELOG.md CHANGED
@@ -2,6 +2,11 @@
2
2
 
3
3
  * TODO: Replace this bullet point with an actual description of a change.
4
4
 
5
+ ### 2.2.0 (19 December 2025)
6
+
7
+ * Upgraded PostgreSQL to 18.1. ([#26](https://github.com/hausgold/alarmable/pull/26))
8
+ * Migrated to a shared Rubocop configuration for HAUSGOLD gems ([#27](https://github.com/hausgold/alarmable/pull/27))
9
+
5
10
  ### 2.1.0 (24 October 2025)
6
11
 
7
12
  * Upgraded PostgreSQL to 17.6. ([#23](https://github.com/hausgold/alarmable/pull/23))
data/Envfile CHANGED
@@ -1,3 +1,4 @@
1
1
  LANG=en_US.UTF-8
2
2
  LANGUAGE=en_US.UTF-8
3
3
  LC_ALL=en_US.UTF-8
4
+ RUBOCOP_CACHE_ROOT=/app/tmp
data/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2023 HAUSGOLD | talocasa GmbH
3
+ Copyright (c) 2025 HAUSGOLD | talocasa GmbH
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
data/docker-compose.yml CHANGED
@@ -1,6 +1,6 @@
1
1
  services:
2
2
  db:
3
- image: hausgold/postgres:17.6
3
+ image: hausgold/postgres:18.1
4
4
  network_mode: bridge
5
5
  ports: ["5432"]
6
6
  volumes:
@@ -3,7 +3,7 @@
3
3
  # The gem version details.
4
4
  module Alarmable
5
5
  # The version of the +alarmable+ gem
6
- VERSION = '2.1.0'
6
+ VERSION = '2.2.0'
7
7
 
8
8
  class << self
9
9
  # Returns the version of gem as a string.
data/lib/alarmable.rb CHANGED
@@ -69,7 +69,6 @@ module Alarmable
69
69
  attr_accessor :alarm_job, :alarm_base_date_property
70
70
  end
71
71
 
72
- # rubocop:disable Metrics/BlockLength -- because Active Support like it
73
72
  included do
74
73
  # Hooks
75
74
  after_initialize :validate_alarm_settings, :alarm_defaults
@@ -121,7 +120,7 @@ module Alarmable
121
120
 
122
121
  # Generate a unique and recalculatable identifier for a given alarm
123
122
  # object. We build a hash of the primary keys (before_minutes and
124
- # channel) to achive this. Afterwards, this alarm id is used to
123
+ # channel) to achieve this. Afterwards, this alarm id is used to
125
124
  # reference dedicated scheduled jobs and track their updates. (Or cancel
126
125
  # them accordingly)
127
126
  #
@@ -141,8 +140,6 @@ module Alarmable
141
140
  # @param alarm [Hash] The alarm object
142
141
  # @return [Object] The new alarm_jobs instance (partial)
143
142
  # Example: { "alarm id": "job id" }
144
- #
145
- # rubocop:disable Metrics/AbcSize -- because its already broken down
146
143
  def reschedule_alarm_job(alarm)
147
144
  # Symbolize the hash keys (just to be sure).
148
145
  alarm = alarm.symbolize_keys
@@ -169,7 +166,6 @@ module Alarmable
169
166
  # Construct a new alarm_jobs partial instance for this job
170
167
  { id => job.job_id }
171
168
  end
172
- # rubocop:enable Metrics/AbcSize
173
169
 
174
170
  # Initiate a reschedule for each alarm in the alarm settings and
175
171
  # cancel all left-overs.
@@ -204,5 +200,4 @@ module Alarmable
204
200
  alarm_jobs.each_value { |job_id| alarm_job.cancel(job_id) }
205
201
  end
206
202
  end
207
- # rubocop:enable Metrics/BlockLength
208
203
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: alarmable
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hermann Mayer