Skip to content

Commit

Permalink
Bump lints from 2.1.1 to 3.0.0 in /dart (#1695)
Browse files Browse the repository at this point in the history
* Bump lints from 2.1.1 to 3.0.0 in /dart

Bumps [lints](https://github.com/dart-lang/lints) from 2.1.1 to 3.0.0.
- [Release notes](https://github.com/dart-lang/lints/releases)
- [Changelog](https://github.com/dart-lang/lints/blob/main/CHANGELOG.md)
- [Commits](dart-lang/lints@v2.1.1...v3.0.0)

---
updated-dependencies:
- dependency-name: lints
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* update

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: GIancarlo Buenaflor <giancarlo_buenaflor@yahoo.com>
  • Loading branch information
dependabot[bot] and buenaflor authored Dec 21, 2023
1 parent 0118295 commit bc29768
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 38 deletions.
2 changes: 2 additions & 0 deletions dart/lib/sentry.dart
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
// found in the LICENSE file.

/// A pure Dart client for Sentry.io crash reporting.
library sentry_dart;

export 'src/run_zoned_guarded_integration.dart';
export 'src/hub.dart';
// useful for tests
Expand Down
35 changes: 12 additions & 23 deletions dart/lib/src/protocol/sentry_transaction.dart
Original file line number Diff line number Diff line change
Expand Up @@ -17,45 +17,34 @@ class SentryTransaction extends SentryEvent {

SentryTransaction(
this.tracer, {
SentryId? eventId,
super.eventId,
DateTime? timestamp,
String? platform,
String? serverName,
String? release,
String? dist,
String? environment,
super.platform,
super.serverName,
super.release,
super.dist,
super.environment,
String? transaction,
dynamic throwable,
Map<String, String>? tags,
@Deprecated(
'Additional Data is deprecated in favor of structured [Contexts] and should be avoided when possible')
Map<String, dynamic>? extra,
SentryUser? user,
Contexts? contexts,
List<Breadcrumb>? breadcrumbs,
SdkVersion? sdk,
SentryRequest? request,
super.user,
super.contexts,
super.breadcrumbs,
super.sdk,
super.request,
String? type,
Map<String, SentryMeasurement>? measurements,
SentryTransactionInfo? transactionInfo,
}) : super(
eventId: eventId,
timestamp: timestamp ?? tracer.endTimestamp,
platform: platform,
serverName: serverName,
release: release,
dist: dist,
environment: environment,
transaction: transaction ?? tracer.name,
throwable: throwable ?? tracer.throwable,
tags: tags ?? tracer.tags,
// ignore: deprecated_member_use_from_same_package
extra: extra ?? tracer.data,
user: user,
contexts: contexts,
breadcrumbs: breadcrumbs,
sdk: sdk,
request: request,
type: _type,
) {
startTimestamp = tracer.startTimestamp;
Expand All @@ -64,7 +53,7 @@ class SentryTransaction extends SentryEvent {
spans = tracer.children;
this.measurements = measurements ?? {};

this.contexts.trace = spanContext.toTraceContext(
contexts.trace = spanContext.toTraceContext(
sampled: tracer.samplingDecision?.sampled,
status: tracer.status,
);
Expand Down
6 changes: 2 additions & 4 deletions dart/lib/src/sentry_attachment/io_sentry_attachment.dart
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,10 @@ class IoSentryAttachment extends SentryAttachment {
IoSentryAttachment.fromFile(
File file, {
String? filename,
String? attachmentType,
String? contentType,
super.attachmentType,
super.contentType,
}) : super.fromLoader(
loader: () => file.readAsBytes(),
filename: filename ?? file.uri.pathSegments.last,
attachmentType: attachmentType,
contentType: contentType,
);
}
15 changes: 5 additions & 10 deletions dart/lib/src/sentry_transaction_context.dart
Original file line number Diff line number Diff line change
Expand Up @@ -15,21 +15,16 @@ class SentryTransactionContext extends SentrySpanContext {
SentryTransactionContext(
this.name,
String operation, {
String? description,
super.description,
this.parentSamplingDecision,
SentryId? traceId,
SpanId? spanId,
SpanId? parentSpanId,
super.traceId,
super.spanId,
super.parentSpanId,
this.transactionNameSource,
this.samplingDecision,
String? origin,
super.origin,
}) : super(
operation: operation,
description: description,
traceId: traceId,
spanId: spanId,
parentSpanId: parentSpanId,
origin: origin,
);

factory SentryTransactionContext.fromSentryTrace(
Expand Down
1 change: 1 addition & 0 deletions dart/lib/src/utils/sample_rate_format.dart
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
// ignore: dangling_library_doc_comments
/// Code ported & adapted from `intl` package
/// https://pub.dev/packages/intl
///
Expand Down
2 changes: 1 addition & 1 deletion dart/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ dependencies:
dev_dependencies:
build_runner: ^2.4.2
mockito: ^5.1.0
lints: ^2.0.0
lints: ^3.0.0
test: ^1.21.1
yaml: ^3.1.0 # needed for version match (code and pubspec)
collection: ^1.16.0
Expand Down

0 comments on commit bc29768

Please sign in to comment.