René's URL Explorer Experiment


Title: util: process signal to exit code utility by ErickWendel · Pull Request #60963 · nodejs/node · GitHub

Open Graph Title: util: process signal to exit code utility by ErickWendel · Pull Request #60963 · nodejs/node

X Title: util: process signal to exit code utility by ErickWendel · Pull Request #60963 · nodejs/node

Description: Description Adds util.convertProcessSignalToExitCode() utility function to convert signal names (e.g., SIGTERM, SIGKILL) to their corresponding POSIX exit codes. When a child process is terminated by a signal, the code parameter in the 'exit' and 'close' events is null. This utility allows users to convert the signal parameter to the POSIX standard exit code. Example import { spawn } from 'node:child_process'; import { once } from 'node:events'; import { convertProcessSignalToExitCode } from 'node:util'; const ls = spawn('ls', ['-lh', '/usr']); ls.kill(); const [code, signal] = await once(ls, 'exit'); const exitCode = convertProcessSignalToExitCode(signal); console.log(`signal ${signal}, POSIX exit code: ${exitCode}`); // signal SIGTERM, POSIX exit code: 143 Note: While Windows doesn't natively support POSIX signals, Node.js provides a cross-platform abstraction that emulates signal behavior. This allows convertProcessSignalToExitCode() to work consistently across all platforms, returning the same POSIX exit codes on both Unix-like systems and Windows. Refs #60285 #60720

Open Graph Description: Description Adds util.convertProcessSignalToExitCode() utility function to convert signal names (e.g., SIGTERM, SIGKILL) to their corresponding POSIX exit codes. When a child process is terminated ...

X Description: Description Adds util.convertProcessSignalToExitCode() utility function to convert signal names (e.g., SIGTERM, SIGKILL) to their corresponding POSIX exit codes. When a child process is terminated ...

Opengraph URL: https://github.com/nodejs/node/pull/60963

X: @github

direct link

Domain: github.com

route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:d0dcfd46-fb6d-3800-48b4-7275492a3f0f
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idC902:70BDC:3DAFD6:547E03:6A4C7EC3
html-safe-nonce16d017e9f04c1f53acce1b064096566a9cf85fbd0f47e31830dcdbcc1a78eb5a
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDOTAyOjcwQkRDOjNEQUZENjo1NDdFMDM6NkE0QzdFQzMiLCJ2aXNpdG9yX2lkIjoiNzIwOTIxNDc0NTQyMDUyOTM0NyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac8618da327809d614ae3f650e7c2440eef25d994bcbdf8228be7429c0d8c31ffb
hovercard-subject-tagpull_request:3075671929
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/nodejs/node/pull/60963/files
twitter:imagehttps://avatars.githubusercontent.com/u/8060102?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/8060102?s=400&v=4
og:image:altDescription Adds util.convertProcessSignalToExitCode() utility function to convert signal names (e.g., SIGTERM, SIGKILL) to their corresponding POSIX exit codes. When a child process is terminated ...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None3d11bb817438277de2a940854450e83a7d32b6aeb5014e9e6b00a6423900251c
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/nodejs/node git https://github.com/nodejs/node.git
octolytics-dimension-user_id9950313
octolytics-dimension-user_loginnodejs
octolytics-dimension-repository_id27193779
octolytics-dimension-repository_nwonodejs/node
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id27193779
octolytics-dimension-repository_network_root_nwonodejs/node
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releasecd470457e909b9d062f8002cf438ba870e6acff6
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/nodejs/node/pull/60963/files#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fnodejs%2Fnode%2Fpull%2F60963%2Ffiles
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
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
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://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/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fnodejs%2Fnode%2Fpull%2F60963%2Ffiles
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=nodejs%2Fnode
Reloadhttps://github.com/nodejs/node/pull/60963/files
Reloadhttps://github.com/nodejs/node/pull/60963/files
Reloadhttps://github.com/nodejs/node/pull/60963/files
Please reload this pagehttps://github.com/nodejs/node/pull/60963/files
nodejs https://github.com/nodejs
nodehttps://github.com/nodejs/node
Please reload this pagehttps://github.com/nodejs/node/pull/60963/files
Notifications https://github.com/login?return_to=%2Fnodejs%2Fnode
Fork 36k https://github.com/login?return_to=%2Fnodejs%2Fnode
Star 118k https://github.com/login?return_to=%2Fnodejs%2Fnode
Code https://github.com/nodejs/node
Issues 1.4k https://github.com/nodejs/node/issues
Pull requests 964 https://github.com/nodejs/node/pulls
Actions https://github.com/nodejs/node/actions
Projects https://github.com/nodejs/node/projects
Security and quality 0 https://github.com/nodejs/node/security
Insights https://github.com/nodejs/node/pulse
Code https://github.com/nodejs/node
Issues https://github.com/nodejs/node/issues
Pull requests https://github.com/nodejs/node/pulls
Actions https://github.com/nodejs/node/actions
Projects https://github.com/nodejs/node/projects
Security and quality https://github.com/nodejs/node/security
Insights https://github.com/nodejs/node/pulse
Sign up for GitHub https://github.com/signup?return_to=%2Fnodejs%2Fnode%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2Fnodejs%2Fnode%2Fissues%2Fnew%2Fchoose
nodejs-github-bothttps://github.com/nodejs-github-bot
nodejs:mainhttps://github.com/nodejs/node/tree/main
ErickWendel:erickwendel/add-convert-process-signal-to-exit-codehttps://github.com/ErickWendel/node/tree/erickwendel/add-convert-process-signal-to-exit-code
Conversation 19 https://github.com/nodejs/node/pull/60963
Commits 7 https://github.com/nodejs/node/pull/60963/commits
Checks 30 https://github.com/nodejs/node/pull/60963/checks
Files changed https://github.com/nodejs/node/pull/60963/files
Please reload this pagehttps://github.com/nodejs/node/pull/60963/files
util: process signal to exit code utility https://github.com/nodejs/node/pull/60963/files#top
Show all changes 7 commits https://github.com/nodejs/node/pull/60963/files
54035da util: add convertProcessSignalToExitCode utility ErickWendel Nov 14, 2025 https://github.com/nodejs/node/pull/60963/commits/54035dacc583dbd29166778e7c3a5afd1848e28e
42dbd61 doc: document convertProcessSignalToExitCode usage ErickWendel Dec 5, 2025 https://github.com/nodejs/node/pull/60963/commits/42dbd61fc1c18727fb6284b1113bf920df23ff2e
51cfb9e fixup! util: add convertProcessSignalToExitCode utility ErickWendel Dec 5, 2025 https://github.com/nodejs/node/pull/60963/commits/51cfb9e6ec630b5ed48a6b4aee82865ff5c721f9
b107877 fixup! util: add convertProcessSignalToExitCode utility ErickWendel Dec 8, 2025 https://github.com/nodejs/node/pull/60963/commits/b107877fd54f1203ed5d7500e6538600903cc978
8337df1 fixup! doc: document convertProcessSignalToExitCode usage ErickWendel Dec 8, 2025 https://github.com/nodejs/node/pull/60963/commits/8337df16c00a12b6f1c09a260a1135be769435f6
ccf99c9 fixup! doc: document convertProcessSignalToExitCode usage ErickWendel Dec 8, 2025 https://github.com/nodejs/node/pull/60963/commits/ccf99c9574efd3391cab9ab79ff67071664a9a1f
8bbb912 fixup! util: add convertProcessSignalToExitCode utility ErickWendel Dec 10, 2025 https://github.com/nodejs/node/pull/60963/commits/8bbb912b71a570837361d2282a6fe01e50d44dad
Clear filters https://github.com/nodejs/node/pull/60963/files
Please reload this pagehttps://github.com/nodejs/node/pull/60963/files
Please reload this pagehttps://github.com/nodejs/node/pull/60963/files
child_process.md https://github.com/nodejs/node/pull/60963/files#diff-fb4d08d898bf0f72e95ea3627f5838fdf1c4b5adc303cd7c8f526da13e57faf5
util.md https://github.com/nodejs/node/pull/60963/files#diff-ca3b15ffa821a7666a735ddf0ec6f2d8f1d839b4d14ccd09e5af4e0e6443ca0e
util.js https://github.com/nodejs/node/pull/60963/files#diff-f70ef1e11e07dbfe54a7470ee790031f214ed08577129d0a9d3891d7310c0a35
util.js https://github.com/nodejs/node/pull/60963/files#diff-3fb720f70ea34fb2975fd6c38ac4b6b6131373be2abfa4760dfaae8a25daaee2
test-util-convert-signal-to-exit-code.mjs https://github.com/nodejs/node/pull/60963/files#diff-27a621d79fb2f9183cb1bb4de6d236cdf2eca692ff4fb13d3ee70f72f1c2c1f0
doc/api/child_process.mdhttps://github.com/nodejs/node/pull/60963/files#diff-fb4d08d898bf0f72e95ea3627f5838fdf1c4b5adc303cd7c8f526da13e57faf5
View file https://github.com/ErickWendel/node/blob/8bbb912b71a570837361d2282a6fe01e50d44dad/doc/api/child_process.md
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/nodejs/node/pull/60963/{{ revealButtonHref }}
https://github.com/nodejs/node/pull/60963/files#diff-fb4d08d898bf0f72e95ea3627f5838fdf1c4b5adc303cd7c8f526da13e57faf5
https://github.com/nodejs/node/pull/60963/files#diff-fb4d08d898bf0f72e95ea3627f5838fdf1c4b5adc303cd7c8f526da13e57faf5
https://github.com/nodejs/node/pull/60963/files#diff-fb4d08d898bf0f72e95ea3627f5838fdf1c4b5adc303cd7c8f526da13e57faf5
https://github.com/nodejs/node/pull/60963/files#diff-fb4d08d898bf0f72e95ea3627f5838fdf1c4b5adc303cd7c8f526da13e57faf5
https://github.com/nodejs/node/pull/60963/files#diff-fb4d08d898bf0f72e95ea3627f5838fdf1c4b5adc303cd7c8f526da13e57faf5
https://github.com/nodejs/node/pull/60963/files#diff-fb4d08d898bf0f72e95ea3627f5838fdf1c4b5adc303cd7c8f526da13e57faf5
https://github.com/nodejs/node/pull/60963/files#diff-fb4d08d898bf0f72e95ea3627f5838fdf1c4b5adc303cd7c8f526da13e57faf5
doc/api/util.mdhttps://github.com/nodejs/node/pull/60963/files#diff-ca3b15ffa821a7666a735ddf0ec6f2d8f1d839b4d14ccd09e5af4e0e6443ca0e
View file https://github.com/ErickWendel/node/blob/8bbb912b71a570837361d2282a6fe01e50d44dad/doc/api/util.md
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/nodejs/node/pull/60963/{{ revealButtonHref }}
https://github.com/nodejs/node/pull/60963/files#diff-ca3b15ffa821a7666a735ddf0ec6f2d8f1d839b4d14ccd09e5af4e0e6443ca0e
https://github.com/nodejs/node/pull/60963/files#diff-ca3b15ffa821a7666a735ddf0ec6f2d8f1d839b4d14ccd09e5af4e0e6443ca0e
lib/internal/util.jshttps://github.com/nodejs/node/pull/60963/files#diff-f70ef1e11e07dbfe54a7470ee790031f214ed08577129d0a9d3891d7310c0a35
View file https://github.com/ErickWendel/node/blob/8bbb912b71a570837361d2282a6fe01e50d44dad/lib/internal/util.js
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/nodejs/node/pull/60963/{{ revealButtonHref }}
https://github.com/nodejs/node/pull/60963/files#diff-f70ef1e11e07dbfe54a7470ee790031f214ed08577129d0a9d3891d7310c0a35
https://github.com/nodejs/node/pull/60963/files#diff-f70ef1e11e07dbfe54a7470ee790031f214ed08577129d0a9d3891d7310c0a35
https://github.com/nodejs/node/pull/60963/files#diff-f70ef1e11e07dbfe54a7470ee790031f214ed08577129d0a9d3891d7310c0a35
https://github.com/nodejs/node/pull/60963/files#diff-f70ef1e11e07dbfe54a7470ee790031f214ed08577129d0a9d3891d7310c0a35
https://github.com/nodejs/node/pull/60963/files#diff-f70ef1e11e07dbfe54a7470ee790031f214ed08577129d0a9d3891d7310c0a35
https://github.com/nodejs/node/pull/60963/files#diff-f70ef1e11e07dbfe54a7470ee790031f214ed08577129d0a9d3891d7310c0a35
https://github.com/nodejs/node/pull/60963/files#diff-f70ef1e11e07dbfe54a7470ee790031f214ed08577129d0a9d3891d7310c0a35
https://github.com/nodejs/node/pull/60963/files#diff-f70ef1e11e07dbfe54a7470ee790031f214ed08577129d0a9d3891d7310c0a35
lib/util.jshttps://github.com/nodejs/node/pull/60963/files#diff-3fb720f70ea34fb2975fd6c38ac4b6b6131373be2abfa4760dfaae8a25daaee2
View file https://github.com/ErickWendel/node/blob/8bbb912b71a570837361d2282a6fe01e50d44dad/lib/util.js
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/nodejs/node/pull/60963/{{ revealButtonHref }}
https://github.com/nodejs/node/pull/60963/files#diff-3fb720f70ea34fb2975fd6c38ac4b6b6131373be2abfa4760dfaae8a25daaee2
https://github.com/nodejs/node/pull/60963/files#diff-3fb720f70ea34fb2975fd6c38ac4b6b6131373be2abfa4760dfaae8a25daaee2
https://github.com/nodejs/node/pull/60963/files#diff-3fb720f70ea34fb2975fd6c38ac4b6b6131373be2abfa4760dfaae8a25daaee2
https://github.com/nodejs/node/pull/60963/files#diff-3fb720f70ea34fb2975fd6c38ac4b6b6131373be2abfa4760dfaae8a25daaee2
test/parallel/test-util-convert-signal-to-exit-code.mjshttps://github.com/nodejs/node/pull/60963/files#diff-27a621d79fb2f9183cb1bb4de6d236cdf2eca692ff4fb13d3ee70f72f1c2c1f0
View file https://github.com/ErickWendel/node/blob/8bbb912b71a570837361d2282a6fe01e50d44dad/test/parallel/test-util-convert-signal-to-exit-code.mjs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/nodejs/node/pull/60963/{{ revealButtonHref }}
Please reload this pagehttps://github.com/nodejs/node/pull/60963/files
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.