Add support for embedder-managed session state in V8InspectorSession [v8/v8 : main]

0 views
Skip to first unread message

Andrey Kosyakov (Gerrit)

unread,
Jun 11, 2026, 4:22:02 PM (3 days ago) Jun 11
to Simon Zünd, Kim-Anh Tran, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, devtools-...@chromium.org, v8-re...@googlegroups.com
Attention needed from Kim-Anh Tran and Simon Zünd

Andrey Kosyakov voted and added 1 comment

Votes added by Andrey Kosyakov

Commit-Queue+1

1 comment

Patchset-level comments
File-level comment, Patchset 4 (Latest):
Andrey Kosyakov . resolved

PTAL -- this CL lets us stop sending scripts (as breakpoint conditions) accross the renderers by managing breakpoints on the browser side instead.

Open in Gerrit

Related details

Attention is currently required from:
  • Kim-Anh Tran
  • Simon Zünd
Submit Requirements:
  • requirement satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: Iacbebd99cb3fc4e2fd05217ae2669b1200b81b76
Gerrit-Change-Number: 7922734
Gerrit-PatchSet: 4
Gerrit-Owner: Andrey Kosyakov <ca...@chromium.org>
Gerrit-Reviewer: Andrey Kosyakov <ca...@chromium.org>
Gerrit-Reviewer: Kim-Anh Tran <kim...@chromium.org>
Gerrit-Reviewer: Simon Zünd <szu...@chromium.org>
Gerrit-Attention: Kim-Anh Tran <kim...@chromium.org>
Gerrit-Attention: Simon Zünd <szu...@chromium.org>
Gerrit-Comment-Date: Thu, 11 Jun 2026 20:21:58 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
satisfied_requirement
unsatisfied_requirement
open
diffy

Simon Zünd (Gerrit)

unread,
Jun 12, 2026, 1:00:57 AM (2 days ago) Jun 12
to Andrey Kosyakov, Kim-Anh Tran, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, devtools-...@chromium.org, v8-re...@googlegroups.com
Attention needed from Andrey Kosyakov and Kim-Anh Tran

Simon Zünd voted and added 2 comments

Votes added by Simon Zünd

Code-Review+1

2 comments

File include/v8-inspector.h
Line 371, Patchset 4 (Latest):struct V8_EXPORT URLBreakpoint {
Simon Zünd . unresolved

nit: consistent naming. Unfortunately, all of the inspector (even the API) uses `camelCase` 😞 Here and throughout the CL.

File test/inspector/inspector-test.cc
Line 410, Patchset 4 (Latest): "dispatch, is_fully_trusted, embedder_breakpoints).");
Simon Zünd . unresolved

Why just the breakpoints here instead of a full object representing the embedder state? If we'd pass something like `{ url_breakpoints: [{...}, {...}], }` wouldn't that match what we do on the C++ v8-inspector.h side?

I assume we'll move more state to `EmbedderState` in the future?

Open in Gerrit

Related details

Attention is currently required from:
  • Andrey Kosyakov
  • Kim-Anh Tran
Submit Requirements:
    • requirement satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: Iacbebd99cb3fc4e2fd05217ae2669b1200b81b76
    Gerrit-Change-Number: 7922734
    Gerrit-PatchSet: 4
    Gerrit-Owner: Andrey Kosyakov <ca...@chromium.org>
    Gerrit-Reviewer: Andrey Kosyakov <ca...@chromium.org>
    Gerrit-Reviewer: Kim-Anh Tran <kim...@chromium.org>
    Gerrit-Reviewer: Simon Zünd <szu...@chromium.org>
    Gerrit-Attention: Kim-Anh Tran <kim...@chromium.org>
    Gerrit-Attention: Andrey Kosyakov <ca...@chromium.org>
    Gerrit-Comment-Date: Fri, 12 Jun 2026 05:00:51 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Andrey Kosyakov (Gerrit)

    unread,
    Jun 12, 2026, 2:22:35 PM (2 days ago) Jun 12
    to Simon Zünd, Kim-Anh Tran, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, devtools-...@chromium.org, v8-re...@googlegroups.com
    Attention needed from Kim-Anh Tran and Simon Zünd

    Andrey Kosyakov added 3 comments

    Patchset-level comments
    File-level comment, Patchset 5 (Latest):
    Andrey Kosyakov . resolved

    Review comments addressed, ptal!

    File include/v8-inspector.h
    Line 371, Patchset 4:struct V8_EXPORT URLBreakpoint {
    Simon Zünd . resolved

    nit: consistent naming. Unfortunately, all of the inspector (even the API) uses `camelCase` 😞 Here and throughout the CL.

    Andrey Kosyakov

    Done

    File test/inspector/inspector-test.cc
    Line 410, Patchset 4: "dispatch, is_fully_trusted, embedder_breakpoints).");
    Simon Zünd . resolved

    Why just the breakpoints here instead of a full object representing the embedder state? If we'd pass something like `{ url_breakpoints: [{...}, {...}], }` wouldn't that match what we do on the C++ v8-inspector.h side?

    I assume we'll move more state to `EmbedderState` in the future?

    Andrey Kosyakov

    Yup, makes total sense, done! Re moving more state -- hopefully not. I'm a bit reluctant to move state management to the browser side in general, as it constitutes a layering violation and costs us quite a bit of extra code, so we plan on doing this as an exception only when required by security for now. The ultimate solution would be to leave state management to the client (but this is CDP 2.0).

    For now, I don't see any other strings that are readily expoitable, although I wonder about regexps using for blackboxing a bit:

    https://source.chromium.org/search?q=f:v8%2F.*%2Fv8.*agent-impl%20setstring&sq=&ss=chromium

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Kim-Anh Tran
    • Simon Zünd
    Submit Requirements:
      • requirement satisfiedCode-Owners
      • requirement is not satisfiedCode-Review
      • requirement is not satisfiedReview-Enforcement
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: v8/v8
      Gerrit-Branch: main
      Gerrit-Change-Id: Iacbebd99cb3fc4e2fd05217ae2669b1200b81b76
      Gerrit-Change-Number: 7922734
      Gerrit-PatchSet: 5
      Gerrit-Owner: Andrey Kosyakov <ca...@chromium.org>
      Gerrit-Reviewer: Andrey Kosyakov <ca...@chromium.org>
      Gerrit-Reviewer: Kim-Anh Tran <kim...@chromium.org>
      Gerrit-Reviewer: Simon Zünd <szu...@chromium.org>
      Gerrit-Attention: Kim-Anh Tran <kim...@chromium.org>
      Gerrit-Attention: Simon Zünd <szu...@chromium.org>
      Gerrit-Comment-Date: Fri, 12 Jun 2026 18:22:31 +0000
      Gerrit-HasComments: Yes
      Gerrit-Has-Labels: No
      Comment-In-Reply-To: Simon Zünd <szu...@chromium.org>
      satisfied_requirement
      unsatisfied_requirement
      open
      diffy

      Simon Zünd (Gerrit)

      unread,
      Jun 13, 2026, 10:05:09 AM (22 hours ago) Jun 13
      to Andrey Kosyakov, Kim-Anh Tran, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, devtools-...@chromium.org, v8-re...@googlegroups.com
      Attention needed from Andrey Kosyakov and Kim-Anh Tran

      Simon Zünd voted Code-Review+1

      Code-Review+1
      Open in Gerrit

      Related details

      Attention is currently required from:
      • Andrey Kosyakov
      • Kim-Anh Tran
      Submit Requirements:
        • requirement satisfiedCode-Owners
        • requirement is not satisfiedCode-Review
        • requirement satisfiedReview-Enforcement
        Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
        Gerrit-MessageType: comment
        Gerrit-Project: v8/v8
        Gerrit-Branch: main
        Gerrit-Change-Id: Iacbebd99cb3fc4e2fd05217ae2669b1200b81b76
        Gerrit-Change-Number: 7922734
        Gerrit-PatchSet: 5
        Gerrit-Owner: Andrey Kosyakov <ca...@chromium.org>
        Gerrit-Reviewer: Andrey Kosyakov <ca...@chromium.org>
        Gerrit-Reviewer: Kim-Anh Tran <kim...@chromium.org>
        Gerrit-Reviewer: Simon Zünd <szu...@chromium.org>
        Gerrit-Attention: Kim-Anh Tran <kim...@chromium.org>
        Gerrit-Attention: Andrey Kosyakov <ca...@chromium.org>
        Gerrit-Comment-Date: Sat, 13 Jun 2026 14:05:04 +0000
        Gerrit-HasComments: No
        Gerrit-Has-Labels: Yes
        satisfied_requirement
        unsatisfied_requirement
        open
        diffy
        Reply all
        Reply to author
        Forward
        0 new messages