LoAF: Use document character position for inline scripts [chromium/src : main]

0 views
Skip to first unread message

Blink W3C Test Autoroller (Gerrit)

unread,
Apr 4, 2024, 10:20:59 AMApr 4
to Noam Rosenthal, Chromium LUCI CQ, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org

Message from Blink W3C Test Autoroller

Exportable changes to web-platform-tests were detected in this CL and a pull request in the upstream repo has been made: https://github.com/web-platform-tests/wpt/pull/45542.

When this CL lands, the bot will automatically merge the PR on GitHub if the required GitHub checks pass; otherwise, ecosystem-infra@ team will triage the failures and may contact you.

WPT Export docs:
https://chromium.googlesource.com/chromium/src/+/main/docs/testing/web_platform_tests.md#Automatic-export-process

Open in Gerrit

Related details

Attention set is empty
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement is not satisfiedCode-Review
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Id11e0a9324c529925b11b950d73ed4491410f96d
Gerrit-Change-Number: 5425010
Gerrit-PatchSet: 2
Gerrit-Owner: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Reviewer: Noam Rosenthal <nrose...@chromium.org>
Gerrit-CC: Alexis Menard <alexis...@intel.com>
Gerrit-CC: Blink W3C Test Autoroller <blink-w3c-te...@chromium.org>
Gerrit-CC: Kentaro Hara <har...@chromium.org>
Gerrit-CC: Olga Gerchikov <gerc...@microsoft.com>
Gerrit-Comment-Date: Thu, 04 Apr 2024 14:20:49 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

Michal Mocny (Gerrit)

unread,
Apr 9, 2024, 10:20:24 AMApr 9
to Noam Rosenthal, Kouhei Ueno, Blink W3C Test Autoroller, Chromium LUCI CQ, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org
Attention needed from Kouhei Ueno and Noam Rosenthal

Michal Mocny voted and added 6 comments

Votes added by Michal Mocny

Code-Review+1

6 comments

Patchset-level comments
File-level comment, Patchset 4 (Latest):
Michal Mocny . resolved

LGTM but with some questions. I think this will provide valuable insights and better than the current status-quo, but I wonder if the specific values are fully consistent?

File third_party/blink/renderer/core/html/parser/html_document_parser.cc
Line 1182, Patchset 4 (Latest): current_string.NumberOfCharactersConsumed());
Michal Mocny . unresolved

Will this mark the end of the token where we would prefer the start of the token?

File third_party/blink/renderer/platform/wtf/text/text_position.h
Line 80, Patchset 4 (Latest): : line_(line), column_(column), offset_(offset) {}
Michal Mocny . unresolved

My understanding was that we expose character offset because line/column are expensive to compute needlessly. But from this context it sounds like we already have these values?

Could an alternative spec have provided line/column when available, and character offset as a fallback (or both)

File third_party/blink/web_tests/external/wpt/long-animation-frame/tentative/loaf-source-location-inline-classic-script.html
Line 17, Patchset 4 (Latest): assert_greater_than(script.sourceCharPosition, 0);
Michal Mocny . unresolved

What is the actual value? Would it point to:

  • the start of <script> tag
  • the first char of the script itself
  • the end of one of the above

I think any insight is better than none, but curious!

File third_party/blink/web_tests/external/wpt/long-animation-frame/tentative/loaf-source-location-inline-event-listener.html
Line 17, Patchset 4 (Latest): assert_greater_than(script.sourceCharPosition, 0);
Michal Mocny . unresolved

What is the actual value? Would it point to:

  • the start of <img> tag
  • the first char of the script itself
  • the end of one of the above

(Based on my read it will be different than classic/module script)

File third_party/blink/web_tests/external/wpt/long-animation-frame/tentative/resources/utils.js
Line 142, Patchset 4 (Latest): }).observe({ type: "long-animation-frame", buffered: true }));
Michal Mocny . unresolved

Was buffered needed because these (may) be reported immediately onload and before the test loads?

Open in Gerrit

Related details

Attention is currently required from:
  • Kouhei Ueno
  • Noam Rosenthal
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Id11e0a9324c529925b11b950d73ed4491410f96d
Gerrit-Change-Number: 5425010
Gerrit-PatchSet: 4
Gerrit-Owner: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Reviewer: Kouhei Ueno <kou...@chromium.org>
Gerrit-Reviewer: Michal Mocny <mmo...@chromium.org>
Gerrit-Reviewer: Noam Rosenthal <nrose...@chromium.org>
Gerrit-CC: Alexis Menard <alexis...@intel.com>
Gerrit-CC: Blink W3C Test Autoroller <blink-w3c-te...@chromium.org>
Gerrit-CC: Kentaro Hara <har...@chromium.org>
Gerrit-CC: Olga Gerchikov <gerc...@microsoft.com>
Gerrit-Attention: Kouhei Ueno <kou...@chromium.org>
Gerrit-Attention: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Comment-Date: Tue, 09 Apr 2024 14:20:09 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
satisfied_requirement
unsatisfied_requirement
open
diffy

Noam Rosenthal (Gerrit)

unread,
Apr 9, 2024, 11:44:44 AMApr 9
to Michal Mocny, Kouhei Ueno, Blink W3C Test Autoroller, Chromium LUCI CQ, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org
Attention needed from Kouhei Ueno and Michal Mocny

Noam Rosenthal added 5 comments

File third_party/blink/renderer/core/html/parser/html_document_parser.cc
Line 1182, Patchset 4 (Latest): current_string.NumberOfCharactersConsumed());
Michal Mocny . unresolved

Will this mark the end of the token where we would prefer the start of the token?

Noam Rosenthal

It's the end of the start tag. This would be consistent with character index (or the exchangeable line/column) in dev-tools.

File third_party/blink/renderer/platform/wtf/text/text_position.h
Line 80, Patchset 4 (Latest): : line_(line), column_(column), offset_(offset) {}
Michal Mocny . unresolved

My understanding was that we expose character offset because line/column are expensive to compute needlessly. But from this context it sounds like we already have these values?

Could an alternative spec have provided line/column when available, and character offset as a fallback (or both)

Noam Rosenthal

Correct, though the current spec is constrained to character index, as one common denominator is simple for a start.

File third_party/blink/web_tests/external/wpt/long-animation-frame/tentative/loaf-source-location-inline-classic-script.html
Line 17, Patchset 4 (Latest): assert_greater_than(script.sourceCharPosition, 0);
Michal Mocny . unresolved

What is the actual value? Would it point to:

  • the start of <script> tag
  • the first char of the script itself
  • the end of one of the above

I think any insight is better than none, but curious!

Noam Rosenthal

end of the <script> start tag

File third_party/blink/web_tests/external/wpt/long-animation-frame/tentative/loaf-source-location-inline-event-listener.html
Line 17, Patchset 4 (Latest): assert_greater_than(script.sourceCharPosition, 0);
Michal Mocny . unresolved

What is the actual value? Would it point to:

  • the start of <img> tag
  • the first char of the script itself
  • the end of one of the above

(Based on my read it will be different than classic/module script)

Noam Rosenthal

end of the <img> tag. The attributes for an element are parsed when the element's start tag is consumed. So both in inline event listener and in inline script blocks, the character position would be at the end of the starting tag of the relevant element. I think that's consistent enough

File third_party/blink/web_tests/external/wpt/long-animation-frame/tentative/resources/utils.js
Line 142, Patchset 4 (Latest): }).observe({ type: "long-animation-frame", buffered: true }));
Michal Mocny . unresolved

Was buffered needed because these (may) be reported immediately onload and before the test loads?

Noam Rosenthal

Yes, it's to avoid raciness

Open in Gerrit

Related details

Attention is currently required from:
  • Kouhei Ueno
  • Michal Mocny
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Id11e0a9324c529925b11b950d73ed4491410f96d
Gerrit-Change-Number: 5425010
Gerrit-PatchSet: 4
Gerrit-Owner: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Reviewer: Kouhei Ueno <kou...@chromium.org>
Gerrit-Reviewer: Michal Mocny <mmo...@chromium.org>
Gerrit-Reviewer: Noam Rosenthal <nrose...@chromium.org>
Gerrit-CC: Alexis Menard <alexis...@intel.com>
Gerrit-CC: Blink W3C Test Autoroller <blink-w3c-te...@chromium.org>
Gerrit-CC: Kentaro Hara <har...@chromium.org>
Gerrit-CC: Olga Gerchikov <gerc...@microsoft.com>
Gerrit-Attention: Michal Mocny <mmo...@chromium.org>
Gerrit-Attention: Kouhei Ueno <kou...@chromium.org>
Gerrit-Comment-Date: Tue, 09 Apr 2024 15:44:31 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Michal Mocny <mmo...@chromium.org>
satisfied_requirement
unsatisfied_requirement
open
diffy

Kouhei Ueno (Gerrit)

unread,
Apr 9, 2024, 4:01:59 PMApr 9
to Noam Rosenthal, Michal Mocny, Blink W3C Test Autoroller, Chromium LUCI CQ, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org
Attention needed from Michal Mocny and Noam Rosenthal

Kouhei Ueno added 1 comment

File third_party/blink/renderer/platform/wtf/text/text_position.h
Line 113, Patchset 4 (Latest): unsigned offset_ = 0;
Kouhei Ueno . unresolved

What would `offset_` mean? e.g. how is it different to `columns`? I think we should be careful about changing the TextPosition class.

Open in Gerrit

Related details

Attention is currently required from:
  • Michal Mocny
  • Noam Rosenthal
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Id11e0a9324c529925b11b950d73ed4491410f96d
Gerrit-Change-Number: 5425010
Gerrit-PatchSet: 4
Gerrit-Owner: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Reviewer: Kouhei Ueno <kou...@chromium.org>
Gerrit-Reviewer: Michal Mocny <mmo...@chromium.org>
Gerrit-Reviewer: Noam Rosenthal <nrose...@chromium.org>
Gerrit-CC: Alexis Menard <alexis...@intel.com>
Gerrit-CC: Blink W3C Test Autoroller <blink-w3c-te...@chromium.org>
Gerrit-CC: Kentaro Hara <har...@chromium.org>
Gerrit-CC: Olga Gerchikov <gerc...@microsoft.com>
Gerrit-Attention: Michal Mocny <mmo...@chromium.org>
Gerrit-Attention: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Comment-Date: Tue, 09 Apr 2024 20:01:48 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

Noam Rosenthal (Gerrit)

unread,
Apr 10, 2024, 5:19:46 AMApr 10
to Michal Mocny, Kouhei Ueno, Blink W3C Test Autoroller, Chromium LUCI CQ, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org
Attention needed from Kouhei Ueno and Michal Mocny

Noam Rosenthal added 1 comment

File third_party/blink/renderer/platform/wtf/text/text_position.h
Line 113, Patchset 4 (Latest): unsigned offset_ = 0;
Kouhei Ueno . unresolved

What would `offset_` mean? e.g. how is it different to `columns`? I think we should be careful about changing the TextPosition class.

Noam Rosenthal

It's the character offset regardless of rows/columns. We expose that in long animation frames rather than row/column for performance reasons. I can rename it to char_offset_. Alternative proposals to doing this?

Open in Gerrit

Related details

Attention is currently required from:
  • Kouhei Ueno
  • Michal Mocny
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Id11e0a9324c529925b11b950d73ed4491410f96d
Gerrit-Change-Number: 5425010
Gerrit-PatchSet: 4
Gerrit-Owner: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Reviewer: Kouhei Ueno <kou...@chromium.org>
Gerrit-Reviewer: Michal Mocny <mmo...@chromium.org>
Gerrit-Reviewer: Noam Rosenthal <nrose...@chromium.org>
Gerrit-CC: Alexis Menard <alexis...@intel.com>
Gerrit-CC: Blink W3C Test Autoroller <blink-w3c-te...@chromium.org>
Gerrit-CC: Kentaro Hara <har...@chromium.org>
Gerrit-CC: Olga Gerchikov <gerc...@microsoft.com>
Gerrit-Attention: Kouhei Ueno <kou...@chromium.org>
Gerrit-Attention: Michal Mocny <mmo...@chromium.org>
Gerrit-Comment-Date: Wed, 10 Apr 2024 09:19:33 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Kouhei Ueno <kou...@chromium.org>
satisfied_requirement
unsatisfied_requirement
open
diffy

Kouhei Ueno (Gerrit)

unread,
Apr 11, 2024, 2:28:45 PMApr 11
to Noam Rosenthal, Michal Mocny, Blink W3C Test Autoroller, Chromium LUCI CQ, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org
Attention needed from Michal Mocny and Noam Rosenthal

Kouhei Ueno added 1 comment

Patchset-level comments
Kouhei Ueno . resolved

sorry i'm still reviewing this - in particular trying to come up with TextPosision::offset_ alternative

Open in Gerrit

Related details

Attention is currently required from:
  • Michal Mocny
  • Noam Rosenthal
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Id11e0a9324c529925b11b950d73ed4491410f96d
Gerrit-Change-Number: 5425010
Gerrit-PatchSet: 4
Gerrit-Owner: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Reviewer: Kouhei Ueno <kou...@chromium.org>
Gerrit-Reviewer: Michal Mocny <mmo...@chromium.org>
Gerrit-Reviewer: Noam Rosenthal <nrose...@chromium.org>
Gerrit-CC: Alexis Menard <alexis...@intel.com>
Gerrit-CC: Blink W3C Test Autoroller <blink-w3c-te...@chromium.org>
Gerrit-CC: Kentaro Hara <har...@chromium.org>
Gerrit-CC: Olga Gerchikov <gerc...@microsoft.com>
Gerrit-Attention: Michal Mocny <mmo...@chromium.org>
Gerrit-Attention: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Comment-Date: Thu, 11 Apr 2024 18:28:33 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

Noam Rosenthal (Gerrit)

unread,
Apr 18, 2024, 5:04:34 AMApr 18
to Code Review Nudger, Michal Mocny, Kouhei Ueno, Blink W3C Test Autoroller, Chromium LUCI CQ, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org
Attention needed from Kouhei Ueno and Michal Mocny

Noam Rosenthal added 1 comment

Patchset-level comments
Kouhei Ueno . resolved

sorry i'm still reviewing this - in particular trying to come up with TextPosision::offset_ alternative

Noam Rosenthal

Hi, any progress?

Open in Gerrit

Related details

Attention is currently required from:
  • Kouhei Ueno
  • Michal Mocny
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Id11e0a9324c529925b11b950d73ed4491410f96d
Gerrit-Change-Number: 5425010
Gerrit-PatchSet: 4
Gerrit-Owner: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Reviewer: Kouhei Ueno <kou...@chromium.org>
Gerrit-Reviewer: Michal Mocny <mmo...@chromium.org>
Gerrit-Reviewer: Noam Rosenthal <nrose...@chromium.org>
Gerrit-CC: Alexis Menard <alexis...@intel.com>
Gerrit-CC: Blink W3C Test Autoroller <blink-w3c-te...@chromium.org>
Gerrit-CC: Code Review Nudger <android-build...@prod.google.com>
Gerrit-CC: Kentaro Hara <har...@chromium.org>
Gerrit-CC: Olga Gerchikov <gerc...@microsoft.com>
Gerrit-Attention: Kouhei Ueno <kou...@chromium.org>
Gerrit-Attention: Michal Mocny <mmo...@chromium.org>
Gerrit-Comment-Date: Thu, 18 Apr 2024 09:04:19 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Kouhei Ueno <kou...@chromium.org>
satisfied_requirement
unsatisfied_requirement
open
diffy

Kouhei Ueno (Gerrit)

unread,
Apr 22, 2024, 2:24:38 AMApr 22
to Noam Rosenthal, Code Review Nudger, Michal Mocny, Blink W3C Test Autoroller, Chromium LUCI CQ, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org
Attention needed from Michal Mocny and Noam Rosenthal

Kouhei Ueno voted and added 1 comment

Votes added by Kouhei Ueno

Code-Review+1

1 comment

File third_party/blink/renderer/platform/wtf/text/text_position.h
Line 113, Patchset 4 (Latest): unsigned offset_ = 0;
Kouhei Ueno . unresolved

What would `offset_` mean? e.g. how is it different to `columns`? I think we should be careful about changing the TextPosition class.

Noam Rosenthal

It's the character offset regardless of rows/columns. We expose that in long animation frames rather than row/column for performance reasons. I can rename it to char_offset_. Alternative proposals to doing this?

Kouhei Ueno

I searched for alternatives but I couldn't find path forward. Would you add comment that this is specifically to support the loaf spec?

Open in Gerrit

Related details

Attention is currently required from:
  • Michal Mocny
  • Noam Rosenthal
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Id11e0a9324c529925b11b950d73ed4491410f96d
Gerrit-Change-Number: 5425010
Gerrit-PatchSet: 4
Gerrit-Owner: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Reviewer: Kouhei Ueno <kou...@chromium.org>
Gerrit-Reviewer: Michal Mocny <mmo...@chromium.org>
Gerrit-Reviewer: Noam Rosenthal <nrose...@chromium.org>
Gerrit-CC: Alexis Menard <alexis...@intel.com>
Gerrit-CC: Blink W3C Test Autoroller <blink-w3c-te...@chromium.org>
Gerrit-CC: Code Review Nudger <android-build...@prod.google.com>
Gerrit-CC: Kentaro Hara <har...@chromium.org>
Gerrit-CC: Olga Gerchikov <gerc...@microsoft.com>
Gerrit-Attention: Michal Mocny <mmo...@chromium.org>
Gerrit-Attention: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Comment-Date: Mon, 22 Apr 2024 06:24:22 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Comment-In-Reply-To: Kouhei Ueno <kou...@chromium.org>
Comment-In-Reply-To: Noam Rosenthal <nrose...@chromium.org>
satisfied_requirement
unsatisfied_requirement
open
diffy

Noam Rosenthal (Gerrit)

unread,
Apr 23, 2024, 10:59:57 AMApr 23
to Kouhei Ueno, Code Review Nudger, Michal Mocny, Blink W3C Test Autoroller, Chromium LUCI CQ, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org
Attention needed from Michal Mocny

Noam Rosenthal added 5 comments

File third_party/blink/renderer/core/html/parser/html_document_parser.cc
Line 1182, Patchset 4 (Latest): current_string.NumberOfCharactersConsumed());
Michal Mocny . resolved

Will this mark the end of the token where we would prefer the start of the token?

Noam Rosenthal

It's the end of the start tag. This would be consistent with character index (or the exchangeable line/column) in dev-tools.

Noam Rosenthal

Done

File third_party/blink/renderer/platform/wtf/text/text_position.h
Line 80, Patchset 4 (Latest): : line_(line), column_(column), offset_(offset) {}
Michal Mocny . resolved

My understanding was that we expose character offset because line/column are expensive to compute needlessly. But from this context it sounds like we already have these values?

Could an alternative spec have provided line/column when available, and character offset as a fallback (or both)

Noam Rosenthal

Correct, though the current spec is constrained to character index, as one common denominator is simple for a start.

Noam Rosenthal

Done

File third_party/blink/web_tests/external/wpt/long-animation-frame/tentative/loaf-source-location-inline-classic-script.html
Line 17, Patchset 4 (Latest): assert_greater_than(script.sourceCharPosition, 0);
Michal Mocny . resolved

What is the actual value? Would it point to:

  • the start of <script> tag
  • the first char of the script itself
  • the end of one of the above

I think any insight is better than none, but curious!

Noam Rosenthal

end of the <script> start tag

Noam Rosenthal

Done

File third_party/blink/web_tests/external/wpt/long-animation-frame/tentative/loaf-source-location-inline-event-listener.html
Line 17, Patchset 4 (Latest): assert_greater_than(script.sourceCharPosition, 0);
Michal Mocny . resolved

What is the actual value? Would it point to:

  • the start of <img> tag
  • the first char of the script itself
  • the end of one of the above

(Based on my read it will be different than classic/module script)

Noam Rosenthal

end of the <img> tag. The attributes for an element are parsed when the element's start tag is consumed. So both in inline event listener and in inline script blocks, the character position would be at the end of the starting tag of the relevant element. I think that's consistent enough

Noam Rosenthal

Done

File third_party/blink/web_tests/external/wpt/long-animation-frame/tentative/resources/utils.js
Line 142, Patchset 4 (Latest): }).observe({ type: "long-animation-frame", buffered: true }));
Michal Mocny . resolved

Was buffered needed because these (may) be reported immediately onload and before the test loads?

Noam Rosenthal

Yes, it's to avoid raciness

Noam Rosenthal

Done

Open in Gerrit

Related details

Attention is currently required from:
  • Michal Mocny
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Id11e0a9324c529925b11b950d73ed4491410f96d
Gerrit-Change-Number: 5425010
Gerrit-PatchSet: 4
Gerrit-Owner: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Reviewer: Kouhei Ueno <kou...@chromium.org>
Gerrit-Reviewer: Michal Mocny <mmo...@chromium.org>
Gerrit-Reviewer: Noam Rosenthal <nrose...@chromium.org>
Gerrit-CC: Alexis Menard <alexis...@intel.com>
Gerrit-CC: Blink W3C Test Autoroller <blink-w3c-te...@chromium.org>
Gerrit-CC: Code Review Nudger <android-build...@prod.google.com>
Gerrit-CC: Kentaro Hara <har...@chromium.org>
Gerrit-CC: Olga Gerchikov <gerc...@microsoft.com>
Gerrit-Attention: Michal Mocny <mmo...@chromium.org>
Gerrit-Comment-Date: Tue, 23 Apr 2024 14:59:41 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Michal Mocny <mmo...@chromium.org>
Comment-In-Reply-To: Noam Rosenthal <nrose...@chromium.org>
satisfied_requirement
unsatisfied_requirement
open
diffy

Noam Rosenthal (Gerrit)

unread,
Apr 23, 2024, 11:11:14 AMApr 23
to Kouhei Ueno, Code Review Nudger, Michal Mocny, Blink W3C Test Autoroller, Chromium LUCI CQ, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org
Attention needed from Michal Mocny

Noam Rosenthal voted Commit-Queue+2

Commit-Queue+2
Open in Gerrit

Related details

Attention is currently required from:
  • Michal Mocny
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Review
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Id11e0a9324c529925b11b950d73ed4491410f96d
Gerrit-Change-Number: 5425010
Gerrit-PatchSet: 6
Gerrit-Owner: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Reviewer: Kouhei Ueno <kou...@chromium.org>
Gerrit-Reviewer: Michal Mocny <mmo...@chromium.org>
Gerrit-Reviewer: Noam Rosenthal <nrose...@chromium.org>
Gerrit-CC: Alexis Menard <alexis...@intel.com>
Gerrit-CC: Blink W3C Test Autoroller <blink-w3c-te...@chromium.org>
Gerrit-CC: Code Review Nudger <android-build...@prod.google.com>
Gerrit-CC: Kentaro Hara <har...@chromium.org>
Gerrit-CC: Olga Gerchikov <gerc...@microsoft.com>
Gerrit-Attention: Michal Mocny <mmo...@chromium.org>
Gerrit-Comment-Date: Tue, 23 Apr 2024 15:11:02 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
satisfied_requirement
open
diffy

Noam Rosenthal (Gerrit)

unread,
Apr 23, 2024, 11:11:15 AMApr 23
to Kouhei Ueno, Code Review Nudger, Michal Mocny, Blink W3C Test Autoroller, Chromium LUCI CQ, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org
Attention needed from Michal Mocny

Noam Rosenthal added 2 comments

File third_party/blink/renderer/platform/wtf/text/text_position.h
Line 113, Patchset 4: unsigned offset_ = 0;
Kouhei Ueno . resolved

What would `offset_` mean? e.g. how is it different to `columns`? I think we should be careful about changing the TextPosition class.

Noam Rosenthal

It's the character offset regardless of rows/columns. We expose that in long animation frames rather than row/column for performance reasons. I can rename it to char_offset_. Alternative proposals to doing this?

Kouhei Ueno

I searched for alternatives but I couldn't find path forward. Would you add comment that this is specifically to support the loaf spec?

Noam Rosenthal

Done

File-level comment, Patchset 4:
Kouhei Ueno . resolved

What would `offset_` mean? e.g. how is it different to `columns`? I think we should be careful about changing the TextPosition class.

Noam Rosenthal

It's the character offset regardless of rows/columns. We expose that in long animation frames rather than row/column for performance reasons. I can rename it to char_offset_. Alternative proposals to doing this?

Kouhei Ueno

I searched for alternatives but I couldn't find path forward. Would you add comment that this is specifically to support the loaf spec?

Noam Rosenthal

Done

Gerrit-Comment-Date: Tue, 23 Apr 2024 15:10:58 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
satisfied_requirement
open
diffy

Chromium LUCI CQ (Gerrit)

unread,
Apr 23, 2024, 12:48:53 PMApr 23
to Noam Rosenthal, Kouhei Ueno, Code Review Nudger, Michal Mocny, Blink W3C Test Autoroller, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org

Chromium LUCI CQ submitted the change with unreviewed changes

Unreviewed changes

4 is the latest approved patch-set.
The change was submitted with unreviewed changes in the following files:

```
The name of the file: third_party/blink/renderer/platform/wtf/text/text_position.h
Insertions: 4, Deletions: 0.

The diff is too large to show. Please review the diff.
```

Change information

Commit message:
LoAF: Use document character position for inline scripts

This applies to classic/module script blocks and event content
attributes.
Bug: 328209286
Change-Id: Id11e0a9324c529925b11b950d73ed4491410f96d
Reviewed-by: Michal Mocny <mmo...@chromium.org>
Reviewed-by: Kouhei Ueno <kou...@chromium.org>
Commit-Queue: Noam Rosenthal <nrose...@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1291353}
Files:
  • M third_party/blink/renderer/bindings/core/v8/js_event_handler_for_content_attribute.h
  • M third_party/blink/renderer/core/frame/animation_frame_timing_monitor.cc
  • M third_party/blink/renderer/core/html/parser/html_document_parser.cc
  • M third_party/blink/renderer/core/probe/core_probes.pidl
  • M third_party/blink/renderer/core/script/classic_script.cc
  • M third_party/blink/renderer/core/script/module_script.cc
  • M third_party/blink/renderer/platform/wtf/text/text_position.cc
  • M third_party/blink/renderer/platform/wtf/text/text_position.h
  • A third_party/blink/web_tests/external/wpt/long-animation-frame/tentative/loaf-source-location-inline-classic-script.html
  • A third_party/blink/web_tests/external/wpt/long-animation-frame/tentative/loaf-source-location-inline-event-listener.html
  • A third_party/blink/web_tests/external/wpt/long-animation-frame/tentative/loaf-source-location-inline-module-script.html
  • M third_party/blink/web_tests/external/wpt/long-animation-frame/tentative/resources/utils.js
Change size: M
Delta: 12 files changed, 113 insertions(+), 17 deletions(-)
Branch: refs/heads/main
Submit Requirements:
  • requirement satisfiedCode-Review: +1 by Kouhei Ueno, +1 by Michal Mocny
Open in Gerrit
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: merged
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Id11e0a9324c529925b11b950d73ed4491410f96d
Gerrit-Change-Number: 5425010
Gerrit-PatchSet: 7
Gerrit-Owner: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Reviewer: Chromium LUCI CQ <chromiu...@luci-project-accounts.iam.gserviceaccount.com>
Gerrit-Reviewer: Kouhei Ueno <kou...@chromium.org>
Gerrit-Reviewer: Michal Mocny <mmo...@chromium.org>
Gerrit-Reviewer: Noam Rosenthal <nrose...@chromium.org>
Gerrit-CC: Alexis Menard <alexis...@intel.com>
Gerrit-CC: Blink W3C Test Autoroller <blink-w3c-te...@chromium.org>
open
diffy
satisfied_requirement

Blink W3C Test Autoroller (Gerrit)

unread,
Apr 23, 2024, 1:28:01 PMApr 23
to Noam Rosenthal, Chromium LUCI CQ, Kouhei Ueno, Code Review Nudger, Michal Mocny, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org

Message from Blink W3C Test Autoroller

The WPT PR for this CL has been merged upstream! https://github.com/web-platform-tests/wpt/pull/45542

Open in Gerrit

Related details

Attention set is empty
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Review
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: Id11e0a9324c529925b11b950d73ed4491410f96d
Gerrit-Change-Number: 5425010
Gerrit-PatchSet: 7
Gerrit-Owner: Noam Rosenthal <nrose...@chromium.org>
Gerrit-Reviewer: Chromium LUCI CQ <chromiu...@luci-project-accounts.iam.gserviceaccount.com>
Gerrit-Reviewer: Kouhei Ueno <kou...@chromium.org>
Gerrit-Reviewer: Michal Mocny <mmo...@chromium.org>
Gerrit-Reviewer: Noam Rosenthal <nrose...@chromium.org>
Gerrit-CC: Alexis Menard <alexis...@intel.com>
Gerrit-CC: Blink W3C Test Autoroller <blink-w3c-te...@chromium.org>
Gerrit-CC: Code Review Nudger <android-build...@prod.google.com>
Gerrit-CC: Kentaro Hara <har...@chromium.org>
Gerrit-CC: Olga Gerchikov <gerc...@microsoft.com>
Gerrit-Comment-Date: Tue, 23 Apr 2024 17:27:52 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
satisfied_requirement
open
diffy

Kevin McNee (Gerrit)

unread,
Apr 24, 2024, 11:52:47 AMApr 24
to Noam Rosenthal, Chromium LUCI CQ, Kouhei Ueno, Code Review Nudger, Michal Mocny, Blink W3C Test Autoroller, Alexis Menard, chromium...@chromium.org, Olga Gerchikov, Kentaro Hara, blink-revie...@chromium.org, blink-revie...@chromium.org, blink-revi...@chromium.org, blink-rev...@chromium.org, blink-revie...@chromium.org, blink-re...@chromium.org, blink-...@chromium.org, kinuko...@chromium.org, loading-rev...@chromium.org

Kevin McNee has created a revert of this change

Related details

Attention set is empty
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement satisfiedCode-Review
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: revert
satisfied_requirement
open
diffy
Reply all
Reply to author
Forward
0 new messages