René's URL Explorer Experiment


Title: [EventLoop] Implement enter idle · Issue #254 · reactphp/reactphp · GitHub

Open Graph Title: [EventLoop] Implement enter idle · Issue #254 · reactphp/reactphp

X Title: [EventLoop] Implement enter idle · Issue #254 · reactphp/reactphp

Description: Hello, I'm trying to execute some code in an interval kind of way, but I don't want to interfere with other events that could be trigger in each tick. So, I'm looking into a "enter idle" state. I imagine that in each tick that we will wa...

Open Graph Description: Hello, I'm trying to execute some code in an interval kind of way, but I don't want to interfere with other events that could be trigger in each tick. So, I'm looking into a "enter idle" state. I i...

X Description: Hello, I'm trying to execute some code in an interval kind of way, but I don't want to interfere with other events that could be trigger in each tick. So, I'm looking into a "enter...

Opengraph URL: https://github.com/reactphp/reactphp/issues/254

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"[EventLoop] Implement enter idle","articleBody":"Hello,\n\nI'm trying to execute some code in an interval kind of way, but I don't want to interfere with other events that could be trigger in each tick. So, I'm looking into a \"enter idle\" state.\n\nI imagine that in each tick that we will wait forever to the stream, instead we enter idle and we will wait for stream in the next tick. It should also be an exception that the first tick will not enter idle, but is not that important.\n\nI imagine the following:\n\n``` php\n$loop->addTimer(0.01, function ($timer) use ($loop) {\n    echo 'exit' . PHP_EOL;\n    $loop->end();\n});\n$loop->addTimer(0.005, function ($timer) {\n    echo 'hello' . PHP_EOL;\n});\n$loop->addEnterIdle(function ($loop) {\n    echo 'waiting' . PHP_EOL;\n});\n\n$this->expectOutputString(\n    'waiting' . PHP_EOL . 'hello' . PHP_EOL .\n    'waiting' . PHP_EOL . 'exit' . PHP_EOL\n);\n\n$loop->run();\n```\n\nThe logic I found is:\n\n```\nTick with no timers scheduled and $read || $write == false: if not flag, enter idle and set flag.\nTick with events, unset flag.\n```\n\nFor some time now I'm trying to understand how this should work, but it goes beyond my knowledge.\n\nI asked this a few days ago in the IRC channel, and I was pointed to `futureTick()` of #249. But the differences I need are:\n1. My code need to be executed every possible time without needed to re add the same callback.\n2. My code don't need to be executed when something else (stream read/write; timer) are executing.\n3. My code need to be executed only after something happened (to minimize the processing).\n\nAny help figuring out this will be much appreciated. Thank you.\n","author":{"url":"https://github.com/jm42","@type":"Person","name":"jm42"},"datePublished":"2013-12-27T15:19:51Z","url":"https://github.com/reactphp/reactphp/issues/254"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:ce88100b-1f9c-7d65-f4db-571d5780cc59
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-id840A:31D8FB:5D2D7B:808807:6B009536
html-safe-noncec4fa5b565073911393ff666e485193c833fcf854e6ff1e8551abc4247f28769e
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4NDBBOjMxRDhGQjo1RDJEN0I6ODA4ODA3OjZCMDA5NTM2IiwidmlzaXRvcl9pZCI6IjE0Mzg4MjE0MTYxMTkwODAyNDYiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmacaebb73cbe0b35704e535dc27df3fee61e61248007d0c50c72dd0a5169f8743e3
hovercard-subject-tagissue:24823324
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/reactphp/reactphp/254/issue_layout
twitter:imagehttps://opengraph.githubassets.com/7d4d600a140230bc0f144f4449fd47941e4b129de7d994381803f128a43e1dc1/reactphp/reactphp/issues/254
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/7d4d600a140230bc0f144f4449fd47941e4b129de7d994381803f128a43e1dc1/reactphp/reactphp/issues/254
og:image:altHello, I'm trying to execute some code in an interval kind of way, but I don't want to interfere with other events that could be trigger in each tick. So, I'm looking into a "enter idle" state. I i...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamejm42
hostnamegithub.com
expected-hostnamegithub.com
None552480023d6963d7f188d82f8cd5f3fe5046244607d769b794462821d9ea1b29
turbo-cache-controlno-preview
go-importgithub.com/reactphp/reactphp git https://github.com/reactphp/reactphp.git
octolytics-dimension-user_id1696866
octolytics-dimension-user_loginreactphp
octolytics-dimension-repository_id4287921
octolytics-dimension-repository_nworeactphp/reactphp
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id4287921
octolytics-dimension-repository_network_root_nworeactphp/reactphp
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releasecaf54e38b10face642f6cc1c79e4562e7ee52e3c
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/reactphp/reactphp/issues/254#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Freactphp%2Freactphp%2Fissues%2F254
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Freactphp%2Freactphp%2Fissues%2F254
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=reactphp%2Freactphp
Reloadhttps://github.com/reactphp/reactphp/issues/254
Reloadhttps://github.com/reactphp/reactphp/issues/254
Reloadhttps://github.com/reactphp/reactphp/issues/254
reactphphttps://github.com/reactphp
reactphphttps://github.com/reactphp/reactphp
Codehttps://github.com/reactphp/reactphp
Issueshttps://github.com/reactphp/reactphp/issues
Pull requests5 (5)https://github.com/reactphp/reactphp/pulls
Discussionshttps://github.com/reactphp/reactphp/discussions
Actionshttps://github.com/reactphp/reactphp/actions
Wikihttps://github.com/reactphp/reactphp/wiki
Security and qualityhttps://github.com/reactphp/reactphp/security
Insightshttps://github.com/reactphp/reactphp/insights
https://github.com/reactphp/reactphp
New issuehttps://github.com/login?return_to=https://github.com/reactphp/reactphp/issues/254
New issuehttps://github.com/login?return_to=https://github.com/reactphp/reactphp/issues/254
[EventLoop] Implement enter idlehttps://github.com/reactphp/reactphp/issues/254#top
questionhttps://github.com/reactphp/reactphp/issues?q=state%3Aopen%20label%3A%22question%22
https://github.com/jm42
jm42https://github.com/jm42
on Dec 27, 2013https://github.com/reactphp/reactphp/issues/254#issue-24823324
#249https://github.com/reactphp/reactphp/pull/249
https://github.com/cboden
cbodenhttps://github.com/cboden
on Feb 17, 2014https://github.com/reactphp/reactphp/issues/254#issuecomment-35330053
cbodenhttps://github.com/cboden
questionhttps://github.com/reactphp/reactphp/issues?q=state%3Aopen%20label%3A%22question%22
event-loophttps://github.com/reactphp/reactphp/issues?q=state%3Aopen%20label%3A%22event-loop%22
on Feb 17, 2014https://github.com/reactphp/reactphp/issues/254#event-94364666
https://github.com/jm42
jm42https://github.com/jm42
on Feb 19, 2014https://github.com/reactphp/reactphp/issues/254#issuecomment-35520895
cbodenhttps://github.com/cboden
completedhttps://github.com/reactphp/reactphp/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
on May 31, 2014https://github.com/reactphp/reactphp/issues/254#event-126737496
https://github.com/jm42
jm42https://github.com/jm42
on Jun 17, 2014https://github.com/reactphp/reactphp/issues/254#issuecomment-46302919
Sign up for freehttps://github.com/signup?return_to=https://github.com/reactphp/reactphp/issues/254
Sign in to commenthttps://github.com/login?return_to=https://github.com/reactphp/reactphp/issues/254
questionhttps://github.com/reactphp/reactphp/issues?q=state%3Aopen%20label%3A%22question%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.