[release/8.0] Backport iOS 18+ queue compatibility#1571
Closed
kotlarmilos wants to merge 17 commits intodotnet:release/8.0from
Closed
[release/8.0] Backport iOS 18+ queue compatibility#1571kotlarmilos wants to merge 17 commits intodotnet:release/8.0from
kotlarmilos wants to merge 17 commits intodotnet:release/8.0from
Conversation
…tion (dotnet#1348) * unify adb and main console log output on Android * unify main and appOutputLog for iOS devices * Unify logs for MacCatalyst
…ices and MacCatalyst (dotnet#1383) - Move the logic of unifying the app and main logs to the TestOrchestrator. - Copy system and application logs to the main log after the app has finished.
…el (dotnet#1416) * Test file listener * Fix failing tests * Revert TCP changes * Test TCP connection * Test direct TCP connection * Copy the results file from the device to the host machine * Add TODOs * Test bundles * Test bundles * Fix apple run command * Run apple just-test with the new app bundle * Run apple just-test with the new app bundle * Run apple just-test with the new app bundle * Test scouting queues * Test scouting queues * Test scouting queues * Test scouting queues * Fix tvOS path * Test default queues * Test simulators * Fix OS version parsing and update simulator copy command * Improve OS version validation * Fix null check for simulator * Add logging for device OS version * Use file copy on device and simulators only * Test scouting queues * Implement ResultFileHandler * Test default queues * Update mlaunch version to 1.1.56 * Revert "Update mlaunch version to 1.1.56"
* Update mlaunch version * Test simctl version * Add --use-sim-ctl argument * Add --use-sim-ctl argument * Fix test * Bump mlaunch version * Update Microsoft.Tools.Mlaunch version to 1.1.71 * Fix comment * Remove Xamarin.Hosting.dll from signing configuration
Contains the fix for simctl shutdown --json issue
* Test scouting queues * Test scouting queues * Update command for device copy and adjust timeouts in test projects * Reduce LaunchTimeout to 10s * Update device copy command to use 'mobile' * Revert changes
) * Skip TCP launch timeout if result files are copied directly * Test scouting queues * Add regex for mlaunch exit code detection in iOSExitCodeDetector * Fix exit code check in RunOrchestrator to use expectedExitCode * Capture non-zero exit codes from application runs * Switch back to the default queues
…nd (dotnet#1456) * Refactor device log capturing to use log collect command * Fix tests * Use log show to convert the .logarchive to readable text * Improve device log capturing by adding bundle identifier support for log filtering * Refactor device log capturing to use filtering * Remove --end argument * Remove --predicate argument * Filter output using predicate * Update log collection command to use sudo * Fix escaping in log show command * Refactor log collection to only copy system logs * Revert argument changes * Add logging * Fix log filtering * Fix filtering * Remove filtering * Copy application logs to main * Test scouting queues * Improve log collection error handling * Revert to default queues * Remove process manager * Update log filtering to include system logs in CopyLogsToMainLog method * Fix comment
* Remove cancellation token from CopyResultsAsync * Remove null argument
…rsion (dotnet#1501) * Initial plan * Fix SimulatorsCommand to skip entries without runtimeIdentifier and add tests Co-authored-by: simonrozsival <374616+simonrozsival@users.noreply.github.com> * Completed fix for SimulatorsCommand runtimeIdentifier issue Co-authored-by: simonrozsival <374616+simonrozsival@users.noreply.github.com> * Remove accidentally committed nuget.exe Co-authored-by: simonrozsival <374616+simonrozsival@users.noreply.github.com> * Address review feedback: check version property and improve tests Co-authored-by: simonrozsival <374616+simonrozsival@users.noreply.github.com> * Fix KeyNotFoundException when simulator lacks runtimeIdentifier or version Co-authored-by: simonrozsival <374616+simonrozsival@users.noreply.github.com> * Remove SimulatorsCommandTests as requested Co-authored-by: simonrozsival <374616+simonrozsival@users.noreply.github.com> * Remove nuget.exe and add to .gitignore Co-authored-by: simonrozsival <374616+simonrozsival@users.noreply.github.com> * Remove unnecessary changes from gitignore --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: simonrozsival <374616+simonrozsival@users.noreply.github.com> Co-authored-by: Simon Rozsival <simon@rozsival.com>
…t#1505) * Add support for NUnitV3 content inside TouchUnit result files. * Add a new TouchUnit_NUnitV3 xml result jargon. * Refactor the TouchUnit test report generator to call into the NUnitV2 or NUnitV3 test report generators depending on the embedded content. * Simplify the NUnitV3 test report generator to just look for 'test-case' elements, not caring about any parent nodes. * Make the NUnitV3 test report print the full name of failing tests, not just the name.
…net#1517) * Improve crash report handling in AppTester and ResultFileHandler - Implemented crash report copy when test results are not found - Added CopyCrashReportAsync method to IResultFileHandler for fetching crash reports - Log crash dump * Improve crash report handling to utilize HELIX_WORKITEM_UPLOAD_ROOT if available and improve logging format * Skip crash report copy test on Windows
* Initial plan * Update mlaunch version from 1.1.72 to 1.1.97 Co-authored-by: rmarinho <1235097+rmarinho@users.noreply.github.com> * Update queue for testing * Try lowering Mlaunch --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: rmarinho <1235097+rmarinho@users.noreply.github.com> Co-authored-by: Rui Marinho <me@ruimarinho.net> Co-authored-by: Matous Kozak <55735845+matouskozak@users.noreply.github.com>
…P_CRASH after successful runs (dotnet#1551) * Initial plan * Fix tvOS device communication failures causing false TIMED_OUT and APP_CRASH results Three layered fixes: 1. DeviceLogCapturer: Add 2-minute timeouts to 'log collect' and 'log show' processes in StopCapture() to prevent indefinite blocking when Apple TV device log streaming is broken (fixes apple run TIMED_OUT after mlaunch exits with expected code). 2. ResultFileHandler: Add retry with backoff (up to 3 attempts, 5s/10s/20s delays) to devicectl file copy in CopyResultsAsync() to handle transient device communication errors (com.apple.Mercury.error 1000, RSD error 0xE8000003). 3. TestReporter.ParseResult(): When Success=true was already set by CollectDeviceResult() (test run completed via app end signal), but the results file is missing (devicectl failed), return Succeeded instead of Crashed. Device communication failure after successful test completion is an infrastructure issue, not an app crash. 4. AppTester: Skip crash report retrieval when test run already completed and file copy fails, replacing misleading 'app may have crashed' message with accurate warning. Adds unit tests for retry behavior and the new TestReporter.ParseResult() path. Co-authored-by: steveisok <471438+steveisok@users.noreply.github.com> * Improve test method naming per code review feedback Co-authored-by: steveisok <471438+steveisok@users.noreply.github.com> * Remove accidentally committed .nuget/nuget.exe binary and add to .gitignore Co-authored-by: steveisok <471438+steveisok@users.noreply.github.com> * Address PR review feedback - DeviceLogCapturer: Add WaitForExit() flush after timed WaitForExit() to ensure async stdout/stderr buffers are fully drained before reading them (both log collect and log show processes). - DeviceLogCapturer: Fix _outputPath cleanup on early-return paths (timeout and non-zero exit) by extracting CleanupOutputPath() helper and calling it uniformly. - ResultFileHandler: Make DefaultRetryDelaysMs private (tests inject via constructor); clone the array on assignment to prevent external mutation. - Integration tests: Update osx.13.amd64.open Helix queue to osx.15.amd64.open. Co-authored-by: steveisok <471438+steveisok@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: steveisok <471438+steveisok@users.noreply.github.com>
…otnet#1550) * Initial plan * Add emulator recovery to AdbRunner and update Android commands to attempt recovery before DEVICE_NOT_FOUND Co-authored-by: steveisok <471438+steveisok@users.noreply.github.com> * Android: Attempt emulator recovery before returning DEVICE_NOT_FOUND Co-authored-by: steveisok <471438+steveisok@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: steveisok <471438+steveisok@users.noreply.github.com>
- OperatingSystem.IsMacCatalyst(): guard with #if NET6_0_OR_GREATER - string.Split(char, StringSplitOptions): use Split(char[], StringSplitOptions) overload - Process.Kill(entireProcessTree: true): remove named parameter (not in netstandard) - File.ReadAllTextAsync(): use synchronous File.ReadAllText() Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
f6cd801 to
a29d5f8
Compare
Member
Author
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Backport all iOS 18+ queue compatibility changes to release/8.0. This enables servicing branches of downstream repos (e.g., dotnet/runtime release/8.0-staging) to use XHarness 8.0 with iOS 18+ Helix queues instead of requiring net11 main XHarness.
Cherry-picked commits (16)
Log unification (prerequisite, already in release/9.0):
2159190Unify main and app output logs to improve the UX of failure investigation #1348 - Unify main and app output logs: makes iOS 18 failure investigation practicalef94f7f[apple] [infra] Refactor unification of app and main logs for iOS devices and MacCatalyst #1383 - Refactor log unification for iOS devices and MacCatalyst: prerequisite for log collect refactorCore iOS 18+ file-based result handler chain:
3.
a859d8d#1416 - Handle iOS 18+ test results via file copy instead of TCP tunnel (mlaunch 1.0.256 → 1.1.14 in CLI csproj)4.
faf00a1#1422 - Update mlaunch version to 1.1.71 + --use-sim-ctl5.
8eecd2e#1436 - Update mlaunch to 1.1.72 (simctl shutdown fix)6.
15700cf#1423 - Find TCC.db in multiple locations7.
2e6a37a#1440 - Fix device failures on runtime-extra-platforms8.
dfe773f#1445 - Skip TCP launch timeout if result files are copied directly9.
fe850ca#1456 - Refactor device log capturing to use log collect command10.
dbb478b#1461 - Remove cancellation token from CopyResultsAsync11.
06be2b9#1501 - Fix KeyNotFoundException when simulator lacks runtimeIdentifier12.
8c52965#1505 - Add support for NUnitV3 content inside TouchUnit result files13.
8e192dd#1517 - Improve crash report handling in AppTester and ResultFileHandler14.
4554701#1528 - Update mlaunch to 1.1.9215.
a6f9fe6#1551 - Fix tvOS device communication failures (retry with exponential backoff)16.
e7a795d#1550 - Android: Attempt emulator recovery before DEVICE_NOT_FOUND (nuget.exe binary removed)Skipped:
391c863#1559 (install fix for empty $(NetPrevious)) - not applicable since release/8.0 uses hardcoded TFMs.Adaptation notes for release/8.0
<PackageReference Include="Microsoft.Tools.Mlaunch" Version="1.1.92">)DARC subscription retargeting (to execute after merge)