[Failing test]: Aspire.Cli.EndToEnd.Tests.MultipleAppHostTests.DetachFormatJsonProducesValidJson
- Dominant language
- C#
- Stars
- 6.3k
- Forks
- 991
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 201
Description
### Is there an existing issue for this?
- [x] I have searched the existing issues
### Build information
Build: https://github.com/dotnet/aspire/actions/runs/22925166665
Build error leg or test failing: Aspire.Cli.EndToEnd.Tests.MultipleAppHostTests.DetachFormatJsonProducesValidJson
Pull Request: https://github.com/dotnet/aspire/pull/15110
### Fill in the error message template
## Error Message
Fill the error message using [step by step known issues guidance](https://github.com/dotnet/arcade/blob/main/Documentation/Projects/Build%20Analysis/KnownIssueJsonStepByStep.md).
```json
{
"ErrorMessage": "An unexpected error occurred: Expected depth to be zero at the end of the JSON payload.",
"ErrorPattern": "",
"BuildRetry": false,
"ExcludeConsoleLog": false
}
```
### Other info
- Failing job: https://github.com/dotnet/aspire/actions/runs/22925166665/job/66535776281
- Matching artifact: `logs-Cli.EndToEnd-MultipleAppHostTests-ubuntu-latest`
- Extracted TRX failure:
- `Hex1b.Automation.WaitUntilTimeoutException : WaitUntil timed out after 00:08:20 waiting for:`
- Stack trace points to `Aspire.Cli.EndToEnd.Tests.MultipleAppHostTests.DetachFormatJsonProducesValidJson()` in `tests/Aspire.Cli.EndToEnd.Tests/MultipleAppHostTests.cs:128`
- Test duration: `00:09:13.2227639`
- Artifact recording: `testresults/recordings/DetachFormatJsonProducesValidJson.cast`
- CiInsights currently reports this test as `broken` over the last 180 days with `29/29` failures and `0` passes.
### Full captured test output
Source artifact: `logs-Cli.EndToEnd-MultipleAppHostTests-ubuntu-latest`
TRX StdOut
```text
Temporary workspace created at: /tmp/Aspire.Cli.Tests/TemporaryWorkspaces/813fec7d-ce9f-4c83-a94b-6ffefdf68144
```
TRX ErrorInfo.Message
```text
Hex1b.Automation.WaitUntilTimeoutException : WaitUntil timed out after 00:08:20 waiting for: snapshot =>
{
var successPromptSearcher = new CellPatternSearcher()
.FindPattern(counter.Value.ToString())
.RightText(" OK] $ ");
var result = successPromptSearcher.Search(snapshot);
return result.Count > 0;
}
at Hex1bTestHelpers.cs:92
Terminal (160x48, cursor at 13,5, normal screen):
[10 OK] $ aspire run --detach --format json > output.json
DOTNET_DbgEnableMiniDump is set and the createdump binary does not exist: createdump
\ud83d\udd0d Finding apphosts...
❌ An unexpected error occurred: Expected depth to be zero at the end of the JSON payload. There is an open JSON object or array that should be closed.
LineNumber: 1 | BytePositionInLine: 0.
[11 ERR:1] $
```
TRX StackTrace
```text
at Hex1b.Automation.WaitUntilStep.ExecuteAsync(Hex1bTerminal terminal, Hex1bTerminalInputSequenceOptions options, CancellationToken ct) in /home/runner/work/hex1b/hex1b/src/Hex1b/Automation/WaitUntilStep.cs:line 39
at Hex1b.Automation.Hex1bTerminalInputSequence.ApplyAsync(Hex1bTerminal terminal, CancellationToken ct) in /home/runner/work/hex1b/hex1b/src/Hex1b/Automation/Hex1bTerminalInputSequence.cs:line 41
at Aspire.Cli.EndToEnd.Tests.MultipleAppHostTests.DetachFormatJsonProducesValidJson() in /_/tests/Aspire.Cli.EndToEnd.Tests/MultipleAppHostTests.cs:line 128
--- End of stack trace from previous location ---
```
Terminal output from DetachFormatJsonProducesValidJson.cast
```text
[10 OK] $ aspire run --detach --format json > output.json
DOTNET_DbgEnableMiniDump is set and the createdump binary does not exist: createdump
🔍 Finding apphosts...
⠋ Searching...
⠙ Searching...
⠚ Searching...
⠞ Searching...
⠖ Searching...
⠦ Searching...
⠴ Searching...
⠲ Searching...
⠳ Searching...
⠓ Searching...
⠋ Searching...
⠙ Searching...
⠚ Searching...
⠞ Searching...
⠖ Searching...
⠦ Searching...
⠴ Searching...
⠲ Searching...
⠳ Searching...
⠓ Searching...
⠋ Searching...
⠙ Searching...
⠚ Searching...
⠞ Searching...
⠖ Searching...
❌ An unexpected error occurred: Expected depth to be zero at the end of the JSON payload. There is an open JSON object or array that should be closed.
LineNumber: 1 | BytePositionInLine: 0.
[11 ERR:1] $
```
### Known issue validation
**Build: :mag_right:**
**Result validation:** :warning: Validation could not be done without an Azure DevOps build URL on the issue. Please add it to the "**Build:** :mag_right:" line.
**Validation performed at:** 3/10/2026 10:20:29 PM UTC
📊 **[View CI Failure Report](https://github.com/microsoft/aspire/issues/15113#issuecomment-4174836594)**
Contributor guide
Assessment
This issue has not been assessed yet.