Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • gjs gjs
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 116
    • Issues 116
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 19
    • Merge requests 19
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • GNOMEGNOME
  • gjsgjs
  • Issues
  • #1
Closed
Open
Issue created Oct 03, 2017 by Philip Chimento@ptomato🚮Maintainer

Determine GSource priority of promise resolution

Currently we resolve promises in an idle handler which is queued whenever a promise job is ready to call its callback. We also resolve unconditionally after any gjs_context_eval() call (which corresponds to the JS program finishing.)

The idle handler has priority G_PRIORITY_DEFAULT_IDLE (200) and in GJS 1.48.x I've seen it get starved out when something else is spamming the main loop with expose events at G_PRIORITY_DEFAULT (0). I have yet to confirm this in 1.50.x, but I assume it could still be a problem.

Determine whether the current priority is correct, and whether we should resolve promises at other times (after calling into JS from C?) or through another means (a custom GSource?)

Edited Feb 14, 2018 by Philip Chimento
Assignee
Assign to
Time tracking