Git Product home page Git Product logo

Comments (2)

evanstade avatar evanstade commented on June 25, 2024 1

Perhaps "deprecated" is too strong a word. "Unfavored"? "overused"? "Rarely the best choice"? It seems that "in parallel" is often an under-specification because it introduces races into any algorithm steps that operate on global state, and is unnecessary in the case of steps that operate on local state in the context of a returned promise. It was applied more widely in older specs. What few specs I have written have gotten by with a parallel queue, task source, or the use of promises.

In the case of the clipboard, the problem introduced by this "in parallel" is that "check clipboard read permission" should theoretically always return false, because the step "Return true if the current script is running as a result of user interaction with a "Paste" element created by the user agent or operating system." will always fail, at least under my interpretation of "the current script". It is also racy given that it checks user activation, but "in parallel" steps may execute after transient activation has terminated.

Also it now occurs to me that the read() algorithm should just not reference the permission task source at all because it doesn't actually check any permission at the moment.

from clipboard-apis.

saschanaz avatar saschanaz commented on June 25, 2024
  • the read() algorithm verifies permissions "in parallel", which is, AFAIU, a deprecated way to describe parallelism.

Is there a documentation regarding to this? I heard that "Return promise and run the remaining steps in parallel" pattern is deprecated but never heard that "in parallel" itself is, that's new to me 👀

from clipboard-apis.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.