Bug 236301 - Do not expose in WebIDL the parts of the permission API that are not yet supported
Summary: Do not expose in WebIDL the parts of the permission API that are not yet supp...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: youenn fablet
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2022-02-08 07:55 PST by youenn fablet
Modified: 2022-02-10 09:06 PST (History)
7 users (show)

See Also:


Attachments
Patch (10.18 KB, patch)
2022-02-08 08:02 PST, youenn fablet
no flags Details | Formatted Diff | Diff
Patch for landing (10.65 KB, patch)
2022-02-10 07:44 PST, youenn fablet
ews-feeder: commit-queue-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description youenn fablet 2022-02-08 07:55:04 PST
Some permission API (on change event, worker support) is not yet implemented.
Let's not expose the WebIDL part of it for now.
Comment 1 youenn fablet 2022-02-08 08:02:05 PST
Created attachment 451248 [details]
Patch
Comment 2 Chris Dumez 2022-02-08 11:43:15 PST
Comment on attachment 451248 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=451248&action=review

> Source/WebCore/ChangeLog:3
> +        Disable non yet functional permission API

non -> not ?

Also, don't you mean that you are un-exposing it to workers?

Also, while you unexposed self.PermissionStatus and self.Permissions, I *think* that navigator.permissions is still accessible for workers, no?
Comment 3 youenn fablet 2022-02-08 11:56:31 PST
(In reply to Chris Dumez from comment #2)
> Comment on attachment 451248 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=451248&action=review
> 
> > Source/WebCore/ChangeLog:3
> > +        Disable non yet functional permission API
> 
> non -> not ?
> 
> Also, don't you mean that you are un-exposing it to workers?
> 
> Also, while you unexposed self.PermissionStatus and self.Permissions, I
> *think* that navigator.permissions is still accessible for workers, no?

AFAIK, there is no WorkerNavigator+Permissions.idl so it is not exposed in workers.
Comment 4 Chris Dumez 2022-02-08 11:59:13 PST
Comment on attachment 451248 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=451248&action=review

r=me

>>> Source/WebCore/ChangeLog:3
>>> +        Disable non yet functional permission API
>> 
>> non -> not ?
>> 
>> Also, don't you mean that you are un-exposing it to workers?
>> 
>> Also, while you unexposed self.PermissionStatus and self.Permissions, I *think* that navigator.permissions is still accessible for workers, no?
> 
> AFAIK, there is no WorkerNavigator+Permissions.idl so it is not exposed in workers.

That is a good point. I missed that.

I still think we should clarify the bug title / change log description to match what the patch actually does.

Right now, it makes it sound like you're disabling the permission API entirely.

> Source/WebCore/Modules/permissions/PermissionStatus.idl:31
> +    Exposed=(Window)

Maybe we should add a FIXME to indicate this would be exposed to workers.

> Source/WebCore/Modules/permissions/Permissions.idl:31
> +    Exposed=(Window)

ditto.
Comment 5 youenn fablet 2022-02-10 07:32:22 PST
I filed https://bugs.webkit.org/show_bug.cgi?id=236443 to keep track of permission API in workers.
Comment 6 youenn fablet 2022-02-10 07:44:11 PST
Created attachment 451534 [details]
Patch for landing
Comment 7 EWS 2022-02-10 08:22:59 PST
Committed r289536 (247067@main): <https://commits.webkit.org/247067@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 451534 [details].
Comment 8 Radar WebKit Bug Importer 2022-02-10 08:24:17 PST
<rdar://problem/88756040>