← All tasks
pythonAzureAD/microsoft-authentication-library-for-python #854Not a task: already works

[Bug] enable_broker_on_wsl prints pring to stdout

envgap__AzureAD__microsoft-authentication-library-for-python-854

01 / FAILURE SIGNATURE

As reported upstream

No identifying execution failure has been captured.
Not a benchmark task.
  • The project already builds and runs before the fix, so there is nothing to repair.

02 / ENVIRONMENT RECIPE

Base commit
2a138a5a56444f3a52c5bf33751cc32ad006d126
Manifest
setup.cfg
Reproduce
Awaiting issue-specific recipe
Run under trace
Awaiting a meaningful runtime command

03 / ORIGINAL ISSUE TEXT

AzureAD/microsoft-authentication-library-for-python #854 · read the original issue
**Describe the bug**
Using the `PublicClientApplication.enable_broker_on_wsl` argument, the line `"{{\"ping\",\"success\"}}}` is written to stdout.

**To Reproduce**
```python
from msal import PublicClientApplication


client_id = "REDACTED"
authority = "REDACTED"
scopes = [f"api://{client_id}/.default"]

app = PublicClientApplication(
    client_id=client_id,
    authority=authority,
    enable_broker_on_windows=True,
    enable_broker_on_wsl=True,
)
token = app.acquire_token_interactive(
    scopes=scopes,
    parent_window_handle=PublicClientApplication.CONSOLE_WINDOW_HANDLE,
)
```

**Expected behavior**
Nothing should be output to stdout.

**What you see instead**
```bash
> uv run repro.py
"{{\"ping\",\"success\"}}}"
```

**The MSAL Python version you are using**
1.33.0
Continue on GitHub ↗

04 / LABELS

Labels from the report text only; not yet run

No supported category has been assigned.

Label rules and the text that matched
[]