Skip to content

Commit 5accb52

Browse files
authored
Merge pull request #69 from getsentry/releases/0.8.x
Merge 0.8.3 onto master
2 parents 9e40753 + 70ecbbf commit 5accb52

File tree

16 files changed

+218
-111
lines changed

16 files changed

+218
-111
lines changed

.php_cs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,13 @@
22

33
$finder = Symfony\CS\Finder\DefaultFinder::create()
44
->in(__DIR__ . '/src')
5-
->in(__DIR__ . '/test')
6-
;
5+
->in(__DIR__ . '/test');
76

87
return Symfony\CS\Config\Config::create()
98
->setUsingCache(true)
109
->setUsingLinter(true)
1110
->level(Symfony\CS\FixerInterface::PSR2_LEVEL)
12-
->finder($finder)
13-
;
11+
->fixers(array(
12+
'-psr0',
13+
))
14+
->finder($finder);

CHANGELOG.md

Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
# Changelog
2+
All notable changes to this project will be documented in this file.
3+
4+
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
5+
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
6+
7+
## [Unreleased]
8+
9+
## 0.8.3 - 2017-08-07
10+
### Changed
11+
- Migrate all the options from the config root to `sentry.options` (#68); the affected options are still usable in the old form, but they will generate deprecation notices. They will be dropped in the 1.0 release.
12+
13+
Before:
14+
```yaml
15+
sentry:
16+
app_path: ~
17+
environment: ~
18+
error_types: ~
19+
excluded_app_paths: ~
20+
prefixes: ~
21+
release: ~
22+
```
23+
After:
24+
```yaml
25+
sentry:
26+
options:
27+
app_path: ~
28+
environment: ~
29+
error_types: ~
30+
excluded_app_paths: ~
31+
prefixes: ~
32+
release: ~
33+
```
34+
- Migrate from PSR-0 to PSR-4
35+
36+
## 0.8.2 - 2017-07-28
37+
### Fixed
38+
- Fix previous release with cherry pick of the right commit from #67
39+
40+
## 0.8.1 - 2017-07-27
41+
### Fixed
42+
- Force load of client in console commands to avoid missing notices due to lazy-loading (#67)
43+
44+
## 0.8.0 - 2017-06-19
45+
### Added
46+
- Add `SentryExceptionListenerInterface` and the `exception_listener` option in the configuration (#47) to allow customization of the exception listener
47+
- Add `SentrySymfonyEvents::PRE_CAPTURE` and `SentrySymfonyEvents::SET_USER_CONTEXT` events (#47) to customize event capturing information
48+
- Make listeners' priority customizable through the new `listener_priorities` configuration key
49+
### Fixed
50+
- Make SkipCapture work on console exceptions too
51+
52+
## 0.7.1 - 2017-01-26
53+
### Fixed
54+
- Quote sentry.options in services.yml.
55+
56+
## 0.7.0 - 2017-01-20
57+
### Added
58+
- Expose all configuration options (#36).
59+
60+
## 0.6.0 - 2016-10-24
61+
### Fixed
62+
- Improve app path detection to exclude root folder and exclude vendor.
63+
64+
## 0.5.0 - 2016-09-08
65+
### Changed
66+
- Raise sentry/sentry minimum requirement to ## 1.2.0. - 2017-xx-xx Fixed an issue with a missing import (#24)### . - 2017-xx-xx ``prefixes`` and ``app_path`` will now be bound by default.
67+
68+
## 0.4.0 - 2016-07-21
69+
### Added
70+
- Added ``skip_capture`` configuration for excluding exceptions.
71+
### Changed
72+
- Security services are now optional.
73+
- Console exceptions are now captured.
74+
- Default PHP SDK hooks will now be installed (via ``Raven_Client->install``).
75+
- SDK will now be registered as 'sentry-symfony'.
76+
77+
## 0.3.0 - 2016-05-19
78+
### Added
79+
- Added support for capturing the current user.

CHANGES

Lines changed: 0 additions & 43 deletions
This file was deleted.

CONTRIBUTING.md

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
# Contribution notes
2+
3+
## Release process
4+
5+
* Make sure `CHANGELOG.md` is up to date (add the release date) and the build is green.
6+
* If this is the first release for this minor version, create a new branch for it:
7+
```
8+
$ git checkout -b releases/1.7.x
9+
```
10+
* Update the hardcoded `SentryBundle::VERSION` constant:
11+
```
12+
class SentryBundle extends Bundle
13+
{
14+
const VERSION = '1.7.0';
15+
}
16+
```
17+
* Commit the changes:
18+
```
19+
$ git commit -am "Release 1.7.0"
20+
```
21+
* Tag the new commit:
22+
```
23+
git tag 1.7.0
24+
```
25+
* Push the tag:
26+
```
27+
git push --tags
28+
```
29+
* Switch back to `master`:
30+
```
31+
git checkout master
32+
```
33+
* Add the next minor release to the `CHANGES` file:
34+
```
35+
## 1.8.0 (unreleased)
36+
```
37+
* Update the hardcoded `SentryBundle::VERSION` constant:
38+
```
39+
class Raven_Client
40+
{
41+
const VERSION = '1.8.x-dev';
42+
}
43+
```
44+
* Lastly, update the composer version in ``composer.json``:
45+
46+
```
47+
"extra": {
48+
"branch-alias": {
49+
"dev-master": "1.8.x-dev"
50+
}
51+
}
52+
```
53+
* Commit the changes:
54+
```
55+
$ git commit -am "Cleanup after release 1.7"
56+
```
57+
58+
All done! Composer will pick up the tag and configuration automatically.

README.md

Lines changed: 44 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -62,19 +62,19 @@ sentry:
6262
dsn: "https://public:secret@sentry.example.com/1"
6363
```
6464
65-
### Configuration
65+
## Configuration
6666
67-
The following can be configured via ``app/config/config.yml``.
67+
The following options can be configured via ``app/config/config.yml``.
6868
69-
#### Skip some exceptions
69+
### Skip some exceptions
7070
7171
```yaml
7272
sentry:
7373
skip_capture:
7474
- "Symfony\\Component\\HttpKernel\\Exception\\HttpExceptionInterface"
7575
```
7676
77-
#### Listeners' priority
77+
### Listeners' priority
7878
7979
You can change the priority of the 3 default listeners of this bundle with the `listener_priorities` key of your config.
8080
The default value is `0`, and here are the 3 possible sub-keys:
@@ -88,55 +88,51 @@ listener_priorities:
8888

8989
... respectively for the `onKernelRequest`, `onKernelException` and `onConsoleException` events.
9090

91-
#### Deprecated configuration options
91+
### Options
9292

93-
In previous releases of this bundle, some of the previous options where set outside of the options level of the configuration file. Those still work but are deprecated, and they will be dropped in the 2.x release, so you are advised to abandon them; to provide forward compatibility, they can be used alongside the standard syntax, but values must match. This is a list of those options:
93+
In the following section you will find some of the available options you can configure, listed alphabetically. All available options and a more detailed description of each can be found [here](https://docs.sentry.io/clients/php/config/), in the Sentry documentation.
94+
95+
#### app_path
96+
97+
The base path to your application. Used to trim prefixes and mark frames of the stack trace as part of your application.
9498

9599
```yaml
96100
sentry:
97-
app_path: ~
98-
environment: ~
99-
error_types: ~
100-
prefixes: ~
101-
release: ~
102-
excluded_app_paths: ~
101+
options:
102+
app_path: "/path/to/myapp"
103103
```
104104

105-
#### Options
106-
107-
In the following section you will find some of the available options you can configure. All available options and a more detailed description of each can be found [here](https://docs.sentry.io/clients/php/config/).
108-
109-
##### app_path
105+
#### environment
110106

111-
The base path to your application. Used to trim prefixes and mark frames as part of your application.
107+
The environment your code is running in (e.g. production).
112108

113109
```yaml
114110
sentry:
115111
options:
116-
app_path: "/path/to/myapp"
112+
environment: "%kernel.environment%"
117113
```
118114

119-
##### environment
115+
#### error types
120116

121-
The environment your code is running in (e.g. production).
117+
Define which error types should be reported.
122118

123119
```yaml
124120
sentry:
125121
options:
126-
environment: "%kernel.environment%"
122+
error_types: E_ALL & ~E_DEPRECATED & ~E_NOTICE
127123
```
128124

129-
##### release
125+
#### exception_listener
130126

131-
The version of your application. Often this is the git sha.
127+
This is used to replace the default exception listener that this bundle uses. The value must be a FQCN of a class implementing the SentryExceptionListenerInterface interface. See [Create a Custom ExceptionListener](#create-a-custom-exceptionlistener) for more details.
132128

133129
```yaml
134130
sentry:
135131
options:
136-
release: "beeee2a06521a60e646bbb8fe38702e61e4929bf"
132+
exception_listener: AppBundle\EventListener\MySentryExceptionListener
137133
```
138134

139-
##### prefixes
135+
#### prefixes
140136

141137
A list of prefixes to strip from filenames. Often these would be vendor/include paths.
142138

@@ -147,17 +143,17 @@ sentry:
147143
- /usr/lib/include
148144
```
149145

150-
##### error types
146+
#### release
151147

152-
Define which error types should be reported.
148+
The version of your application. Often this is the Git SHA hash of the commit.
153149

154150
```yaml
155151
sentry:
156152
options:
157-
error_types: E_ALL & ~E_DEPRECATED & ~E_NOTICE
153+
release: "beeee2a06521a60e646bbb8fe38702e61e4929bf"
158154
```
159155

160-
##### tags
156+
#### tags
161157

162158
Define tags for the logged errors.
163159

@@ -169,27 +165,35 @@ sentry:
169165
tag2: tagvalue
170166
```
171167

168+
### Deprecated configuration options
169+
170+
In previous releases of this bundle, up to 0.8.2, some of the previous options where set outside of the options level of the configuration file. Those still work but are deprecated, and they will be dropped in the stable 1.x release, so **you are advised to abandon them**; to provide forward compatibility, they can still be used alongside the standard syntax, but values must match. This is a list of those options:
171+
172+
```yaml
173+
sentry:
174+
app_path: ~
175+
environment: ~
176+
error_types: ~
177+
excluded_app_paths: ~
178+
prefixes: ~
179+
release: ~
180+
```
181+
172182
## Customization
173183

174-
It is possible to customize the configuration of the user context, as well
175-
as modify the client immediately before an exception is captured by wiring
176-
up an event subscriber to the events that are emitted by the default
177-
configured `ExceptionListener` (alternatively, you can also just defined
178-
your own custom exception listener).
184+
It is possible to customize the configuration of the user context, as well as modify the client immediately before an exception is captured by wiring up an event subscriber to the events that are emitted by the default configured `ExceptionListener` (alternatively, you can also just define your own custom exception listener).
179185

180-
### Create a Custom ExceptionListener
186+
### Create a custom ExceptionListener
181187

182-
You can always replace the default `ExceptionListener` with your own custom
183-
listener. To do this, assign a different class to the `exception_listener`
184-
property in your Sentry configuration, e.g.:
188+
You can always replace the default `ExceptionListener` with your own custom listener. To do this, assign a different class to the `exception_listener` property in your Sentry configuration, e.g.:
185189

186190
```yaml
187191
sentry:
188192
options:
189193
exception_listener: AppBundle\EventListener\MySentryExceptionListener
190194
```
191195

192-
... and then define the custom `ExceptionListener`, e.g.:
196+
... and then define the custom `ExceptionListener` that implements the `SentryExceptionListenerInterface`, e.g.:
193197

194198
```php
195199
// src/AppBundle/EventSubscriber/MySentryEventListener.php

composer.json

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,18 @@
2626
"phpunit/phpunit": "^4.6.6"
2727
},
2828
"autoload": {
29-
"psr-0" : {
30-
"Sentry\\SentryBundle\\": "src/"
29+
"psr-4" : {
30+
"Sentry\\SentryBundle\\": "src/Sentry/SentryBundle"
31+
}
32+
},
33+
"autoload-dev": {
34+
"psr-4" : {
35+
"Sentry\\SentryBundle\\Test\\": "test"
3136
}
3237
},
3338
"extra": {
3439
"branch-alias": {
35-
"dev-master": "0.9.x-dev"
40+
"dev-master": "0.8.x-dev"
3641
}
3742
}
3843
}

0 commit comments

Comments
 (0)