ExecuteScript and CallDevToolsProtocolMethod never complete when the result contains an unpaired UTF-16 surrogate
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 48/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- powershell
- Ambito
- backend-api-design
Direzione di ricerca
Start by reproducing the issue in a WebView2 control with the supplied HTML, then compare ExecuteScript and CallDevToolsProtocolMethod with the remote-debugging websocket responses. The report identifies the affected host APIs but names no implementation files or tests, so locating the bridge code will require project familiarity. Done means both calls invoke their completion handlers for results containing an unpaired surrogate, or return a failing HRESULT.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
WebView2 Runtime 155.0.4283.45 (Windows 11), host via webview2-com 0.39.1.
A page whose text holds an unpaired surrogate — e.g. a script that slices a string in the middle of an emoji,
"🐢 name".slice(1) — makes host-side calls on that page never complete:
| call (host API) | text without the half emoji | with it |
|---|---|---|
| ExecuteScript("(() => document.body.innerText)()") | completes | completion handler never invoked (10 s) |
| CallDevToolsProtocolMethod("Accessibility.getFullAXTree", "{}") | completes | completion handler never invoked (5 s) |
The same tab queried over the remote-debugging websocket (CDP Runtime.evaluate with returnByValue, and
Accessibility.getFullAXTree) answers normally: the string comes back with a \udc22 escape and the AX tree has its
nodes. So the content is serializable; only the host bridge drops it.
Repro:
<!doctype html><p id=n></p><button>Post</button>
<script>document.getElementById('n').textContent = "🐢 quiet turtle".slice(1) + " · " + "🐢".slice(0, 1);</script>
Load it in a WebView2 control, then call ExecuteScript("document.body.innerText") or
CallDevToolsProtocolMethod("Accessibility.getFullAXTree", "{}") and wait for the completion handler.
Expected: the handler is invoked — with the JSON carrying the lone surrogate as an escape (as JSON.stringify and CDP
over the websocket do) or replaced by U+FFFD — or with a failing HRESULT. Today it is never invoked, so a host cannot
tell "no answer" from "slow".
Note: for ExecuteScript a script can pass its result through String.prototype.toWellFormed() first; for
CallDevToolsProtocolMethod the text is the page's own, so there is nothing to wrap.
- Lingua principale
- PowerShell
- Stelle
- 526
- Fork
- 68
- Merge medio
- 15g 5h
- PR unite (30g)
- 1
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di MicrosoftEdge/WebView2Feedback
-
bug
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 72/100
MicrosoftEdge/WebView2Feedback#5749 · 1 commento ·
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 30/100
MicrosoftEdge/WebView2Feedback#5786 ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 36/100
MicrosoftEdge/WebView2Feedback#5785 ·
-
[Problem/Bug]:Apertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 18/100
MicrosoftEdge/WebView2Feedback#5783 ·
-
[Problem/Bug]: WebView2 Runtime 156.x prevents New Outlook attachments from opening, Fixed Runtime 155.0.4283.62 worksForse già presa @ambikakunnath l’ha presa 2 giorni fa. Apertabug regression
MicrosoftEdge/WebView2Feedback#5782 · 2 commenti · 1 assegnatario ·
Tutte le issue di MicrosoftEdge/WebView2Feedback
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
google/go-containerregistry#2491 ·
I maintainer di solito rispondono entro 1 giorno
-
Psalm types a #[ServiceMap] className given as a non-::class constant as the constant's ownerApertaagent-ready area:static-analysis bug p3
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
gacela-project/gacela#1048 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
Graphify-Labs/graphify#4860 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
aiac enhancement
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Ingredient import validation accepts negative nutrient values and NaNForse già presa @LukeSekai l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
wger-project/wger#2564 ·
I maintainer di solito rispondono entro 2 giorni