[Webkit-unassigned] [Bug 240715] New: Web Inspector: Assertion Failed: Expect an array of string values CSSCompletions.js:39
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Fri May 20 07:28:23 PDT 2022
https://bugs.webkit.org/show_bug.cgi?id=240715
Bug ID: 240715
Summary: Web Inspector: Assertion Failed: Expect an array of
string values CSSCompletions.js:39
Product: WebKit
Version: WebKit Nightly Build
Hardware: All
OS: All
Status: NEW
Severity: Normal
Priority: P2
Component: Web Inspector
Assignee: webkit-unassigned at lists.webkit.org
Reporter: rcaliman at apple.com
CC: inspector-bugzilla-changes at group.apple.com
```
[Error] Assertion Failed: Expect an array of string values – [] (0)
CSSCompletions (CSSCompletions.js:39)
(anonymous function) (CSSKeywordCompletions.js:233)
(anonymous function) (CSSKeywordCompletions.js:129)
_valueCompletionDataProvider
_updateCompletions (SpreadsheetTextField.js:435)
_handleInput (SpreadsheetTextField.js:422)
_handleInput
```
**Steps to reproduce**
- Open Web Inspector, go to Styles sidebar panel
- Type `var(` on any CSS value
**Result**
No issue in UI or UX, but the assertion above is hit.
**Explanation**
It happens because the `WI.CSSCompletions` instance created in `WI.CSSKeywordCompletions.forFunction()` is initially given an empty array for "var" functions. The actual values are added immediately after instantiation via `WI.CSSCompletions.addValues()`. They come from the custom completion provider referenced by the `additionalFunctionValueCompletionsProvider` option.
There's no reason to have this two step approach. We can provide the result of `additionalFunctionValueCompletionsProvider("var")` at `WI.CSSCompletions` instantiation.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20220520/c769684e/attachment-0001.htm>
More information about the webkit-unassigned
mailing list