Skip to content

DevTools: worker_id should be id & thread for workers should be thread#36631

Merged
atbrakhi merged 1 commit into
servo:mainfrom
atbrakhi:fix_worker_script_thread_naming
Apr 21, 2025
Merged

DevTools: worker_id should be id & thread for workers should be thread#36631
atbrakhi merged 1 commit into
servo:mainfrom
atbrakhi:fix_worker_script_thread_naming

Conversation

@atbrakhi
Copy link
Copy Markdown
Member

This is part of #36562, where I discovered that we are sending thread as context and id for worker is called worked_id. In this PR, I have renamed the worker_id to id and thread is sent as thread and not context. These chages were tested in #36562

Some logs for context(this logs are from firefox instance)

worker_id should be id

{"_from": "server1.conn0.watcher35", "message": {"from": "server1.conn0.watcher35", "target": {"actor": "server1.conn0.watcher34.process7//workerTarget21/workerTarget5", "consoleActor": "server1.conn0.watcher34.process7//workerTarget21/console2", "id": "f454ea34-c76a-4b6e-a079-43ee3128881e", "name": "", "objectsManagerActor": "server1.conn0.watcher34.process7//workerTarget21/objects-manager4", "relatedDocumentInnerWindowId": 15032385539, "targetType": "worker", "threadActor": "server1.conn0.watcher34.process7//workerTarget21/thread1", "tracerActor": "server1.conn0.watcher34.process7//workerTarget21/tracer3", "traits": {"supportsTopLevelTargetFlag": false}, "type": 0, "url": "http://localhost:8000/Documents/codespace/servo/worker.js"}, "type": "target-available-form"}}

Thread should be thread and not context

{"_from": "server1.conn0.watcher35", "message": {"from": "server1.conn0.watcher35", "target": {"actor": "server1.conn0.watcher34.process7//workerTarget21/workerTarget5", "consoleActor": "server1.conn0.watcher34.process7//workerTarget21/console2", "id": "f454ea34-c76a-4b6e-a079-43ee3128881e", "name": "", "objectsManagerActor": "server1.conn0.watcher34.process7//workerTarget21/objects-manager4", "relatedDocumentInnerWindowId": 15032385539, "targetType": "worker", "threadActor": "server1.conn0.watcher34.process7//workerTarget21/thread1", "tracerActor": "server1.conn0.watcher34.process7//workerTarget21/tracer3", "traits": {"supportsTopLevelTargetFlag": false}, "type": 0, "url": "http://localhost:8000/Documents/codespace/servo/worker.js"}, "type": "target-available-form"}}
  • ./mach build -d does not report any errors
  • ./mach test-tidy does not report any errors
  • These changes partially implement devtools: Debugger tab #36027

@atbrakhi atbrakhi changed the title DevTools: worker_id shoud be id & thread for workers should be thread DevTools: worker_id shoud be id & thread for workers should be thread Apr 21, 2025
@atbrakhi atbrakhi requested a review from mrobinson April 21, 2025 15:19
@atbrakhi atbrakhi added this pull request to the merge queue Apr 21, 2025
@simonwuelker simonwuelker changed the title DevTools: worker_id shoud be id & thread for workers should be thread DevTools: worker_id should be id & thread for workers should be thread Apr 21, 2025
Merged via the queue into servo:main with commit 15301df Apr 21, 2025
@atbrakhi atbrakhi deleted the fix_worker_script_thread_naming branch April 21, 2025 16:38
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.

2 participants