Title: Ability for script packs to prevent exit · Issue #543 · scriptcs/scriptcs · GitHub
Open Graph Title: Ability for script packs to prevent exit · Issue #543 · scriptcs/scriptcs
X Title: Ability for script packs to prevent exit · Issue #543 · scriptcs/scriptcs
Description: I'm no JS aficionado, but one thing I've observed in nodejs is that if you have a script which is, for example, listening for an HTTP request, the script does not exit upon completion and the web server continues to listen for requests, ...
Open Graph Description: I'm no JS aficionado, but one thing I've observed in nodejs is that if you have a script which is, for example, listening for an HTTP request, the script does not exit upon completion and the web s...
X Description: I'm no JS aficionado, but one thing I've observed in nodejs is that if you have a script which is, for example, listening for an HTTP request, the script does not exit upon completion and t...
Mail addresses
notifications@github.com
glenn.block@gmail.com
notifications@github.comwrote
glenn.block@gmail.com
glenn.block@gmail.com
notifications@github.comwrote
Opengraph URL: https://github.com/scriptcs/scriptcs/issues/543
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Ability for script packs to prevent exit","articleBody":"I'm no JS aficionado, but one thing I've observed in nodejs is that if you have a script which is, for example, listening for an HTTP request, the script does not exit upon completion and the web server continues to listen for requests, even though the call to `listen()` does not block and subsequent code is executed. I'm told this is because the JS event loop is not empty because of the fact the HTTP server is listening.\n\nCurrently, there is no such equivalent behaviour for scriptcs. I.e. you either allow your script to exit, or you have to explicitly call a method which blocks endlessly or listens for a keypress, etc. as demonstrated in many of the script packs, e.g. WebAPI or Nancy.\n\nI'm wondering if there's some way we can simulate the behaviour of nodejs in these circumstances and remove the need for finalising the script with a blocking call.\n\nDuring a discussion in Jabbr, @davepermen suggested that a script pack can register a call to be made upon the ending the execution of a script. Perhaps all that is required is the ability for a script pack to say 'don't exit upon completion' if a certain call has been made, e.g. for the Nancy pack, that would be `Go()`.\n\nSensible? Or have I gone mad again?\n","author":{"url":"https://github.com/adamralph","@type":"Person","name":"adamralph"},"datePublished":"2014-01-06T00:51:28Z","url":"https://github.com/scriptcs/scriptcs/issues/543"}
| react-profiling | 0 |
| react-import-map | react,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-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:b4636153-6daa-49ea-3dd7-7bfe67a7868d |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 82BA:163716:1FC45DE:2B21261:6B001A9A |
| html-safe-nonce | 5ea08563b01cdad14a766766039e4144bc4afa36ac6d16e75cac0650c9c44d92 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4MkJBOjE2MzcxNjoxRkM0NURFOjJCMjEyNjE6NkIwMDFBOUEiLCJ2aXNpdG9yX2lkIjoiMzE0MDYzNjkzNjU0MTA1MTU0NiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | c185d3d5486fbd597d79762d3b22f127c1aeb68a73ce6ca72e350fffd953159f |
| hovercard-subject-tag | issue:25081301 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/scriptcs/scriptcs/543/issue_layout |
| twitter:image | https://opengraph.githubassets.com/0be4cee42751e3e63b7cb842d9cc337fce3f28dbed94277ac3fadba2b03fdebc/scriptcs/scriptcs/issues/543 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/0be4cee42751e3e63b7cb842d9cc337fce3f28dbed94277ac3fadba2b03fdebc/scriptcs/scriptcs/issues/543 |
| og:image:alt | I'm no JS aficionado, but one thing I've observed in nodejs is that if you have a script which is, for example, listening for an HTTP request, the script does not exit upon completion and the web s... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | adamralph |
| hostname | github.com |
| expected-hostname | github.com |
| None | a2dd2291b1b13cc9c06f27ec92fa3dbaf34116fc24c9347b8539db61884c59f4 |
| turbo-cache-control | no-preview |
| go-import | github.com/scriptcs/scriptcs git https://github.com/scriptcs/scriptcs.git |
| octolytics-dimension-user_id | 3758046 |
| octolytics-dimension-user_login | scriptcs |
| octolytics-dimension-repository_id | 8473240 |
| octolytics-dimension-repository_nwo | scriptcs/scriptcs |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 8473240 |
| octolytics-dimension-repository_network_root_nwo | scriptcs/scriptcs |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 70121d4e855ee0bb7b75cf15d061d91f8863c0f8 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width