-
-
Notifications
You must be signed in to change notification settings - Fork 243
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tracing for File IO integration #1160
Merged
Merged
Changes from 11 commits
Commits
Show all changes
24 commits
Select commit
Hold shift + click to select a range
85df9db
Tracing for File IO integration
marandaneto 0e48d00
add file workflow
marandaneto 0f74b5b
fix pr id
marandaneto 2a999cd
copy tests
marandaneto 2f372ac
add tests for create
marandaneto d6a5de6
fix
marandaneto ac4d4dc
fixes
marandaneto 05ea2c9
add missing tests
marandaneto 153813b
remove
marandaneto 1312453
add extension
marandaneto 244a6f4
fixes
marandaneto 00cd84a
add example
marandaneto 5ce347d
add readme
marandaneto 74a42f1
fixes comments
marandaneto 52bf20d
enable strict analyzer
marandaneto e39ecc7
add integration
marandaneto 1841669
add @experimental annotation
marandaneto a794e14
overwrite pana threshold
marandaneto 6fe9687
Update .craft.yml
marandaneto 7b46c5c
remove not needed items from gh action
marandaneto 35215e2
Merge branch 'feat/sentry_file' of github.com:getsentry/sentry-dart i…
marandaneto 88b6194
add dart file to min test
marandaneto 964eb27
add example
marandaneto de0ca3c
remove example
marandaneto File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
name: sentry-file | ||
on: | ||
push: | ||
branches: | ||
- main | ||
- release/** | ||
pull_request: | ||
paths-ignore: | ||
- 'logging/**' | ||
- 'flutter/**' | ||
- 'dio/**' | ||
|
||
jobs: | ||
cancel-previous-workflow: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Cancel Previous Runs | ||
uses: styfle/cancel-workflow-action@b173b6ec0100793626c2d9e6b90435061f4fc3e5 # [email protected] | ||
with: | ||
access_token: ${{ github.token }} | ||
|
||
build: | ||
name: Build ${{matrix.sdk}} on ${{matrix.os}} | ||
runs-on: ${{ matrix.os }} | ||
timeout-minutes: 30 | ||
defaults: | ||
run: | ||
shell: bash | ||
working-directory: ./file | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ubuntu-latest, windows-latest, macos-latest] | ||
# removing beta because of Dart 2.19.0 | ||
sdk: [stable] | ||
exclude: | ||
- os: macos-latest | ||
sdk: beta | ||
steps: | ||
- uses: dart-lang/setup-dart@6a218f2413a3e78e9087f638a238f6b40893203d # pin@v1 | ||
with: | ||
sdk: ${{ matrix.sdk }} | ||
- uses: actions/checkout@v3 | ||
# coverage with 'chrome' platform hangs the build | ||
- name: Test VM | ||
run: | | ||
dart pub get | ||
dart test -p vm --coverage=coverage --test-randomize-ordering-seed=random --chain-stack-traces | ||
dart pub run coverage:format_coverage --lcov --in=coverage --out=coverage/lcov.info --packages=.dart_tool/package_config.json --report-on=lib | ||
|
||
- uses: codecov/codecov-action@d9f34f8cd5cb3b3eb79b3e4b5dae3a16df499a70 # pin@v3 | ||
if: runner.os == 'Linux' && matrix.sdk == 'stable' | ||
with: | ||
name: sentry_file | ||
files: ./file/coverage/lcov.info | ||
|
||
- uses: VeryGoodOpenSource/very_good_coverage@84e5b54ab888644554e5573dca87d7f76dec9fb3 # [email protected] | ||
if: runner.os == 'Linux' && matrix.sdk == 'stable' | ||
with: | ||
path: './file/coverage/lcov.info' | ||
min_coverage: 81 | ||
|
||
analyze: | ||
uses: ./.github/workflows/analyze.yml | ||
with: | ||
package: file |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../CHANGELOG.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2019 Sentry | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<p align="center"> | ||
<a href="https://sentry.io" target="_blank" align="center"> | ||
<img src="https://sentry-brand.storage.googleapis.com/sentry-logo-black.png" width="280"> | ||
</a> | ||
<br /> | ||
</p> | ||
|
||
Sentry integration for `dart.io.File` | ||
=========== | ||
|
||
| package | build | pub | likes | popularity | pub points | | ||
| ------- | ------- | ------- | ------- | ------- | ------- | | ||
| sentry_file | [![build](https://github.com/getsentry/sentry-dart/workflows/sentry-file/badge.svg?branch=main)](https://github.com/getsentry/sentry-dart/actions?query=workflow%3Asentry-file) | [![pub package](https://img.shields.io/pub/v/sentry_file.svg)](https://pub.dev/packages/sentry_file) | [![likes](https://img.shields.io/pub/likes/sentry_file)](https://pub.dev/packages/sentry_file/score) | [![popularity](https://img.shields.io/pub/popularity/sentry_file)](https://pub.dev/packages/sentry_file/score) | [![pub points](https://img.shields.io/pub/points/sentry_file)](https://pub.dev/packages/sentry_file/score) | ||
|
||
#### Usage | ||
|
||
- Sign up for a Sentry.io account and get a DSN at https://sentry.io. | ||
|
||
- Follow the installing instructions on [pub.dev](https://pub.dev/packages/sentry/install). | ||
|
||
- Initialize the Sentry SDK using the DSN issued by Sentry.io. | ||
|
||
#### Resources | ||
|
||
* [![Documentation](https://img.shields.io/badge/documentation-sentry.io-green.svg)](https://docs.sentry.io/platforms/dart/) | ||
* [![Forum](https://img.shields.io/badge/forum-sentry-green.svg)](https://forum.sentry.io/c/sdks) | ||
* [![Discord](https://img.shields.io/discord/621778831602221064)](https://discord.gg/Ww9hbqr) | ||
* [![Stack Overflow](https://img.shields.io/badge/stack%20overflow-sentry-green.svg)](https://stackoverflow.com/questions/tagged/sentry) | ||
* [![Twitter Follow](https://img.shields.io/twitter/follow/getsentry?label=getsentry&style=social)](https://twitter.com/intent/follow?screen_name=getsentry) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
include: package:lints/recommended.yaml | ||
|
||
analyzer: | ||
marandaneto marked this conversation as resolved.
Show resolved
Hide resolved
|
||
exclude: | ||
- example/** # the example has its own 'analysis_options.yaml' | ||
errors: | ||
# treat missing required parameters as a warning (not a hint) | ||
missing_required_param: error | ||
# treat missing returns as a warning (not a hint) | ||
missing_return: error | ||
# allow having TODOs in the code | ||
todo: ignore | ||
# allow self-reference to deprecated members (we do this because otherwise we have | ||
# to annotate every member in every test, assert, etc, when we deprecate something) | ||
deprecated_member_use_from_same_package: warning | ||
|
||
linter: | ||
rules: | ||
prefer_relative_imports: true | ||
unnecessary_brace_in_string_interps: true | ||
prefer_function_declarations_over_variables: false | ||
no_leading_underscores_for_local_identifiers: false | ||
avoid_renaming_method_parameters: false | ||
unawaited_futures: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import 'package:sentry/sentry.dart'; | ||
|
||
Future<void> main() async { | ||
// ATTENTION: Change the DSN below with your own to see the events in Sentry. Get one at sentry.io | ||
const dsn = | ||
'https://[email protected]/5428562'; | ||
|
||
await Sentry.init( | ||
(options) { | ||
options.dsn = dsn; | ||
}, | ||
appRunner: runApp, // Init your App. | ||
); | ||
} | ||
|
||
Future<void> runApp() async {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
export 'src/sentry_file.dart'; | ||
export 'src/sentry_file_extension.dart'; |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Double check if craft is already able to auto create the first entry in release registry
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@adinauer @kamilogorek what's the outcome of that problem, do we still need to do the release registry dance manually or is it fine now?
getsentry/sentry-release-registry#85
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it's still "broken"