You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Includes descriptions of requestPermission() and option descriptor = {}. However, implementation at Chromium 81 does not appear to perform any check for type or value of descriptor
status = await handle . requestPermission({ writable = false })
status = await handle . requestPermission({ writable = true })
Context
While testing two branches of code that composed which uses Native File System noticed that in one branch had written {writable:true} while in the other branch had written {write:true}, checked the specification for which was expected, the output had no observable difference, continued checking other inputs, output.
Following
const dir = await self.chooseFileSystemEntries({type: "openDirectory"})
the result of
const status = await dir.requestPermission()
const status = await dir.requestPermission({write: true})
const status = await dir.requestPermission({[void 0]: true})
const status = await dir.requestPermission(void 0)
const status = await dir.requestPermission({writable: false})
are identical, that is, "granted", meaning descriptor does not have any effect on the output of requestPermission() in any case.
Hexcles
changed the title
Test requestPermission() and FileSystemHandlePermissionDescriptor [Native File System][Missing Coverage]
Test requestPermission() and FileSystemHandlePermissionDescriptor [Native File System]
Jan 31, 2020
Native File System (Draft Community Group Report, 18 November 2019)
Includes descriptions of
requestPermission()
and optiondescriptor = {}
. However, implementation at Chromium 81 does not appear to perform any check for type or value ofdescriptor
In pertinent part 2.2. The FileSystemHandle interface
and 2.2.2. The requestPermission() method
Context
While testing two branches of code that composed which uses Native File System noticed that in one branch had written
{writable:true}
while in the other branch had written{write:true}
, checked the specification for which was expected, the output had no observable difference, continued checking other inputs, output.Following
the result of
const status = await dir.requestPermission()
const status = await dir.requestPermission({write: true})
const status = await dir.requestPermission({[void 0]: true})
const status = await dir.requestPermission(void 0)
const status = await dir.requestPermission({writable: false})
are identical, that is,
"granted"
, meaningdescriptor
does not have any effect on the output ofrequestPermission()
in any case.It is not immediately clear what the purpose of
descriptor
is, nor what algorithm, if any, is applicable to the optional value passed (https://bugs.chromium.org/p/chromium/issues/detail?id=1042018).It is clear that list items, 2., 3., 4. are not expected values of
descriptor
per the current iteration of the Native File System draft.The text was updated successfully, but these errors were encountered: