Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce InspectorLifecycleAgent and InspectorTestReporterAgent #15194

Draft
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

Jarred-Sumner
Copy link
Collaborator

What does this PR do?

This adds two new APIs to the WebKit Inspector Protocol when used in Bun.

This lets you implement a test reporter on top of the WebKit inspector protocol. This also unlocks reporting runtime errors in editor diagnostic APIs without the debugger attached.

The API will change a little more before this merges. The diagnostics need to already be stacktraced since the client may not have the debugger connected.

How did you verify your code works?

This will need some tests before it merges.

@robobun
Copy link

robobun commented Nov 17, 2024

@Jarred-Sumner, your commit f46e3f6 has 1 failures in #6295:

  • test/cli/run/require-cache.test.ts - 1 failing on 🪟 x64
  • for (size_t i = 0; i < exception.stack.frames_len; i++) {
    ZigStackFrame* frame = &exception.stack.frames_ptr[i];
    lineColumns->addItem(frame->position.line_zero_based + 1);
    lineColumns->addItem(frame->position.column_zero_based + 1);
    Copy link
    Collaborator

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Suggested change
    lineColumns->addItem(frame->position.column_zero_based + 1);
    lineColumns->addItem(frame->position.column_zero_based + 1);
    urls->addItem(frame->source_url.toWTFString());

    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    None yet
    Projects
    None yet
    Development

    Successfully merging this pull request may close these issues.

    3 participants