Skip to content

HTTP Client Errors don't impact session #3742

@philipphofmann

Description

@philipphofmann

Description

The HTTP Client errors captured here

[SentrySDK captureEvent:event];

don't impact the session because captureEvent doesn't increment session errors in the Hub

- (SentryId *)captureEvent:(SentryEvent *)event
{
return [self captureEvent:event withScope:self.scope];
}
- (SentryId *)captureEvent:(SentryEvent *)event withScope:(SentryScope *)scope
{
return [self captureEvent:event withScope:scope additionalEnvelopeItems:@[]];
}
- (SentryId *)captureEvent:(SentryEvent *)event
withScope:(SentryScope *)scope
additionalEnvelopeItems:(NSArray<SentryEnvelopeItem *> *)additionalEnvelopeItems
{
SentryClient *client = _client;
if (client != nil) {
return [client captureEvent:event
withScope:scope
additionalEnvelopeItems:additionalEnvelopeItems];
}
return SentryId.empty;
}

Metadata

Metadata

Labels

Breaking-changeshould go in a major release (breaks apps, changes default configs in a major way)BugCocoa

Projects

Status

Backlog

Relationships

None yet

Development

No branches or pull requests

Issue actions