-
-
Notifications
You must be signed in to change notification settings - Fork 230
chore: optimize the CI flow #4247
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
Merged
Merged
Changes from all commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
8367f01
WIP: CI: provide faster feedback for "no mobile" builds
jpnurmi 01864e2
fix boolean comparison
jpnurmi a279a42
Sentry.Native.targets: RID is not set during `dotnet pack`
jpnurmi c42e972
Install build deps for the time being
jpnurmi 2047423
try all non-publishing builds
jpnurmi 739e1fd
try packing Sentry.Maui
jpnurmi 093ef1e
Merge remote-tracking branch 'upstream/main' into ci/flow
jpnurmi 37b8286
drop build deps, libcurl no more needed
jpnurmi 9a7968c
run integration tests from build on all platforms
jpnurmi 08dfcee
update outdated comment
jpnurmi 7937dc4
try switching to sparse checkout before integration test
jpnurmi ab4def7
try sparse checkout for publishing build only and refetch the pkg
jpnurmi 4e83199
restore CI_PUBLISHING_BUILD conditions to safe guard
jpnurmi 3b3aebb
use System.Runtime.InteropServices.RuntimeInformation
jpnurmi 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 hidden or 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 |
|---|---|---|
|
|
@@ -183,10 +183,7 @@ jobs: | |
| name: ${{ matrix.target || runner.os }}-verify-test-results | ||
| path: "**/*.received.*" | ||
|
|
||
| # To save time and disk space, we only create and archive the NuGet packages when we're actually releasing. | ||
|
|
||
| - name: Create NuGet Packages | ||
| if: env.CI_PUBLISHING_BUILD == 'true' | ||
| run: dotnet pack Sentry-CI-Build-${{ matrix.target || runner.os }}.slnf -c Release --no-build --nologo | ||
|
|
||
| - name: Archive NuGet Packages | ||
|
|
@@ -199,44 +196,24 @@ jobs: | |
| src/**/Release/*.nupkg | ||
| src/**/Release/*.snupkg | ||
|
|
||
| integration-test: | ||
| needs: build | ||
| name: Integration test (${{ matrix.container || matrix.os }}) | ||
| runs-on: ${{ matrix.os }} | ||
| container: ${{ matrix.container }} | ||
|
|
||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| include: | ||
| - os: ubuntu-22.04 # Pin ubuntu to ensure mono is installed | ||
| - os: ubuntu-22.04-arm | ||
| - os: ubuntu-latest | ||
| container: ghcr.io/getsentry/sentry-dotnet-alpine:3.21 | ||
| - os: macos-15 # Pin macos to get the version of Xcode that we need: https://github.com/actions/runner-images/issues/10703 | ||
| - os: windows-latest | ||
| - os: windows-11-arm | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - name: Sparse checkout | ||
| if: env.CI_PUBLISHING_BUILD == 'true' | ||
|
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not sure if this is specific to the publishing build or macOS, but here's the integration test error for reference. Other runners have no problems, this only occurs on macOS if we don't switch to a sparse checkout: |
||
| uses: actions/checkout@v4 | ||
| with: | ||
| # We only check out what is absolutely necessary to reduce a chance of local files impacting | ||
| # integration tests, e.g. Directory.Build.props, nuget.config, ... | ||
| sparse-checkout: | | ||
| Directory.Build.props | ||
|
jpnurmi marked this conversation as resolved.
|
||
| integration-test | ||
| .github | ||
|
|
||
| - name: Fetch NuGet Packages | ||
| if: env.CI_PUBLISHING_BUILD == 'true' | ||
| uses: actions/download-artifact@v4 | ||
| with: | ||
| name: ${{ github.sha }} | ||
| path: src | ||
|
|
||
| - name: Setup Environment | ||
| uses: ./.github/actions/environment | ||
|
|
||
| - name: Test | ||
| - name: Integration test | ||
| uses: getsentry/github-workflows/sentry-cli/integration-test/@v2 | ||
| with: | ||
| path: integration-test | ||
|
|
||
This file contains hidden or 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 hidden or 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
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.
Uh oh!
There was an error while loading. Please reload this page.