govuk_app_config 7.0.0 → 7.1.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: 76fa770ac62a07fcd63f201603abd10f76cd092f5b8ea632ae85115e63d644f7
4
- data.tar.gz: 8344992578b29ccca21e15079d5f4ecf07c28efbe416dea31afbb972032c4caa
3
+ metadata.gz: 55aadf4fdd96125cdacca3f50768c74005433fecadc2271248ec9d59973b5f80
4
+ data.tar.gz: 577a4e8061b5458e912d1ab16236c7011f8695c53fd8427a3378529c482466cc
5
5
  SHA512:
6
- metadata.gz: 936ed693e0d29e65e844bc30d7108553690939a442c9f80c66f924239ec9c5c852733f6f351ad7925ed372fc0d1d12ab0c591af44448fe5d7429df252dc038e6
7
- data.tar.gz: 3e5ab1885b814cf722e1c856b9778c9360f8afd617e437a713a100f959bcfbe47059c1cac358f9edc3c13cc5747135cc5f8c5755564fc908194afa27ddc669bb
6
+ metadata.gz: 5736f71ea147e470900633ea0a46625b316703a38d636b18b30b5ad616af62b715f4c990953cc97c7950fdee3f5226629938d1e5f84c06a6373a36a194cda8ff
7
+ data.tar.gz: af25d35eb1873b93b7848a12f406a4c83dcde832b9af598d2263815bc4be071bf6c20ca5300f23a86102e4afe99cd226687dc3673341960a91059ff75c400111
data/CHANGELOG.md CHANGED
@@ -1,13 +1,17 @@
1
+ # 7.1.0
2
+
3
+ * `GovukError` now allows specifying any name for the Sentry environment tag via the `SENTRY_CURRENT_ENV` environment variable. The environment name no longer has to match one of a fixed set of strings in order for `GovukError` to log events to Sentry.
4
+
1
5
  # 7.0.0
2
6
 
3
7
  * BREAKING: Remove [unicorn](https://rubygems.org/gems/unicorn/) and `GovukUnicorn`. All production GOV.UK apps are now using [Puma](https://rubygems.org/gems/puma/) instead.
4
8
  * `GovukStatsd` is deprecated and will be removed in a future major release.
5
9
 
6
- ## 6.0.1
10
+ # 6.0.1
7
11
 
8
12
  * Add support for configuring timeouts for puma-based applications
9
13
 
10
- ## 6.0.0
14
+ # 6.0.0
11
15
 
12
16
  * BREAKING: Drop support for Ruby 2.7
13
17
  * Register the Prometheus exporter in Sinatra middleware
data/README.md CHANGED
@@ -40,13 +40,11 @@ To run an app locally with Puma, run: `bundle exec puma` or `bundle exec rails s
40
40
 
41
41
  ### Automatic error reporting
42
42
 
43
- If you include `govuk_app_config` in your `Gemfile`, Rails' autoloading mechanism will make sure that your application is configured to send errors to Sentry.
44
-
45
- Your app will have to have the following environment variables set:
43
+ If you include `govuk_app_config` in your `Gemfile` and set the following environment variables, your application will automatically log errors to Sentry.
46
44
 
47
45
  - `SENTRY_DSN` - the [Data Source Name (DSN)][dsn] for Sentry
48
- - `SENTRY_CURRENT_ENV` - e.g. "production". Make sure it is [configured to be active](#active-sentry-environments).
49
- - `GOVUK_STATSD_PREFIX` - a Statsd prefix like `govuk.apps.application-name.hostname` (deprecated; use Prometheus instead).
46
+ - `SENTRY_CURRENT_ENV` - the `environment` tag to pass to Sentry, for example `production`
47
+ - `GOVUK_STATSD_PREFIX` - a Statsd prefix like `govuk.apps.application-name.hostname` (deprecated; statsd functionality will be removed in a future release)
50
48
 
51
49
  [dsn]: https://docs.sentry.io/quickstart/#about-the-dsn
52
50
 
@@ -73,18 +71,6 @@ GovukError.notify(
73
71
  )
74
72
  ```
75
73
 
76
- ### Active Sentry environments
77
-
78
- GovukError will only send errors to Sentry if your `SENTRY_CURRENT_ENV` matches one of the 'active environments' in the [default configuration](https://github.com/alphagov/govuk_app_config/blob/master/lib/govuk_app_config/govuk_error/configure.rb). This is to prevent temporary test environments from flooding our Sentry account with errors.
79
-
80
- You can add your environment to the list of active Sentry environments like so:
81
-
82
- ```ruby
83
- GovukError.configure do |config|
84
- config.enabled_environments << "my-test-environment"
85
- end
86
- ```
87
-
88
74
  ### Error configuration
89
75
 
90
76
  You can exclude certain errors from being reported using this:
@@ -13,19 +13,6 @@ module GovukError
13
13
  end
14
14
 
15
15
  def set_up_defaults
16
- # These are the environments (described by the `SENTRY_CURRENT_ENV`
17
- # ENV variable) where we want to capture Sentry errors. If
18
- # `SENTRY_CURRENT_ENV` isn't in this list, or isn't defined, then
19
- # don't capture the error.
20
- self.enabled_environments = %w[
21
- integration-blue-aws
22
- integration-eks
23
- staging
24
- staging-eks
25
- production
26
- production-eks
27
- ]
28
-
29
16
  self.excluded_exceptions = [
30
17
  # Default ActionDispatch rescue responses
31
18
  "ActionController::RoutingError",
@@ -1,3 +1,3 @@
1
1
  module GovukAppConfig
2
- VERSION = "7.0.0".freeze
2
+ VERSION = "7.1.0".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: govuk_app_config
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.0.0
4
+ version: 7.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - GOV.UK Dev
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-04-11 00:00:00.000000000 Z
11
+ date: 2023-04-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: logstasher
@@ -321,7 +321,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
321
321
  - !ruby/object:Gem::Version
322
322
  version: '0'
323
323
  requirements: []
324
- rubygems_version: 3.4.11
324
+ rubygems_version: 3.4.12
325
325
  signing_key:
326
326
  specification_version: 4
327
327
  summary: Base configuration for GOV.UK applications