Execute and Control System Processes
Overview
Tools to run system processes in the background. It can check if a background process is running; wait on a background process to finish; get the exit status of finished processes; kill background processes. It can read the standard output and error of the processes, using non-blocking connections. 'processx' can poll a process for standard output or error, with a timeout. It can also poll several processes at once.
- New experimental
pipelineR6 class for running two or more processes connected by kernel-level pipes, like a Unix shell pipeline (cmd1 | cmd2 | cmd3). Data flows directly between child processes without passing through R. Works on Unix and Windows (#280). - New "Process cleanup" article.
- New
linux_pdeathsigargument toprocess$new(): on Linux, the child process receives the specified signal when the parent R process exits. Set toTRUEforSIGTERM, or pass an integer signal number directly (e.g.tools::SIGKILL). Ignored on non-Linux platforms (#36). - New
process$get_end_time()method returns the time when the process exited as aPOSIXct, orNULLif it is still running (#218). process$new()andrun()now supportpty = TRUEon Windows 10 version 1809 and later, in addition to Unix. The Windows implementation uses the ConPTY API (CreatePseudoConsole). The API is loaded dynamically so processx continues to load on older Windows and emits a clear error ifpty = TRUEis requested on an unsupported version (#231).
Show all changes in 3.9.0Hide the rest of the changes in 3.9.0
run()now supportspty = TRUEandpty_optionsto run a process in a pseudo-terminal (PTY) on Unix and Windows (see above). This causes the child to see a real terminal, so programs that disable colour output or interactive behaviour when not attached to a terminal will behave as if they are.stderris merged intostdout(the result's$stderris alwaysNULL). A file-basedstdinargument is also supported: its contents are fed to the process via the PTY master, followed by an EOF signal (#230).process$new()now supports">>"as a prefix forstdoutandstderrfile paths (e.g.stdout = ">>output.log"), which appends output to the file instead of truncating it. The file is created if it does not exist (#403).env = "current"now works correctly as a standalone value, inheriting the full environment of the current process (#399).run()andprocess$new()now supportencoding = "binary"to capture binary output. In this moderun()returnsstdoutandstderras raw vectors, andprocess$read_output()/process$read_error()return raw vectors instead of character strings. All bytes are preserved exactly, including null bytes and non-UTF-8 byte sequences (#406).- New
process$read_output_bytes(),process$read_error_bytes()methods andconn_read_bytes()function for reading raw bytes from a processx connection directly (#406). - On Linux,
process$get_start_time()now returns the correct wall-clock start time. Previously it was systematically ~0.3–0.5 s too early because the boot time was read from/proc/stat btime, which is truncated to whole seconds. processx now derives the boot time fromCLOCK_REALTIME − CLOCK_MONOTONIC, which has nanosecond precision. The ps package is updated in tandem to accept handles created by either the old or the new method, so new ps + old processx continues to work (#394, #402).
From NEWS.md in the release
Install
Health
- OK13 OK2026-08-05
- NOTE12 OK, 1 NOTE2026-08-01
- OK13 OK2026-06-09
- ERROR12 OK, 1 ERROR2026-06-08
- OK12 OK2026-04-25
Show 5 earlier changesHide 5 earlier changes
- WARNING13 OK, 1 WARNING2026-04-24
- OK14 OK2026-04-09
- WARNING9 OK, 4 NOTE, 1 WARNING2026-03-21
- NOTE13 OK, 1 NOTE2026-03-17
- OK14 OK2026-03-10
Documentation
The repository also keeps web-only articles.
- Help pages
- 13 (3 internal)includes a package overview page
- Examples that run
- 83%5 run in a plain check (3 of them under a condition) · 1 never run
- Exported functions with examples
- 55%
- Documented parameters
- 69%
- Return-value docs
- 55%
- Help pages citing references
- 0%
Downloads
Repository
- PRs merged (all time)
- 89%
- Median days to close, 50 most recently updated closed issues
- 41
- Median days to close, 50 most recently updated closed PRs
- 0
Stars over time
Forks over time
Releases over time
Issues over time
PRs over time
13 development-tooling and community-health practices detected across 6 families in the upstream repository
Checks run against github.com/r-lib/processx on 2026-10-11.
The R CMD check workflow runs on Linux, macOS and Windows, and on R-devel
GitHub Pages site last deployed 2026-05-17 · The repository has a site deploy workflow
pkgdown site last built 2026-04-22
Show all practicesHide 2 practices
Dependencies
Installing processx adds 2 packages (1 with compiled code, 231 KB of source tarballs). Heaviest: ps 168 KB, R6 63 KB.
Show the 48 most downloaded dependentsHide the 48 most downloaded dependents
and 38 more dependents and 49 packages that suggest it on CRAN ↗
Code & Tests
People & History
Pick two releases to compare their code metrics.
- RR 4.6.0 released · 2026-04-24
- 3.9.0Latest2026-04-22 · current release · diff ↗ ·
added 4 exports
conn_create_proc_pipepair, conn_read_bytes, pipeline, processx_conn_read_bytes - 3.8.72026-04-01 · diff ↗
- RR 4.5.0 released · 2025-04-11
- 3.8.62025-02-21 · diff ↗
- 3.8.52025-01-08 · diff ↗
- RR 4.4.0 released · 2024-04-24
- 3.8.42024-03-16 · diff ↗
- 3.8.32023-12-10 · diff ↗
- 3.8.22023-06-30 · diff ↗
- RR 4.3.0 released · 2023-04-21
- 3.8.12023-04-18 · diff ↗
- 3.8.02022-10-26 · diff ↗
- 3.7.02022-07-07 · diff ↗ ·
added 7 exports
conn_accept_unix_socket, conn_connect_fifo, conn_connect_unix_socket, conn_create_fifo, conn_create_unix_socket, conn_file_name, conn_unix_socket_state - 3.6.12022-06-17 · diff ↗
- 3.6.02022-06-10 · diff ↗
Show 24 earlier eventsHide 24 earlier events
- RR 4.2.0 released · 2022-04-22
- 3.5.32022-03-25 · diff ↗
- RR 4.1.0 released · 2021-05-18
- 3.5.2
- 3.5.12021-04-04 · diff ↗
- 3.5.0
- 3.4.52020-11-30 · diff ↗
- 3.4.42020-09-03 · diff ↗
- 3.4.32020-07-05 · diff ↗
- RR 4.0.0 released · 2020-04-24
- 3.4.22020-02-09 · diff ↗
- 3.4.12019-07-18 · diff ↗
- 3.4.0
- 3.3.1
- RR 3.6.0 released · 2019-04-26
- 3.3.02019-03-10 · diff ↗
- 3.2.12018-12-05 · diff ↗ ·
added 7 exports
base64_decode, base64_encode, processx_conn_close, processx_conn_is_incomplete, processx_conn_read_chars, processx_conn_read_lines, processx_conn_write - 3.2.02018-08-16 · diff ↗ ·
added 11 exports
conn_create_fd, conn_create_file, conn_create_pipepair, conn_disable_inheritance, conn_get_fileno, conn_is_incomplete, conn_read_chars, conn_read_lines, conn_set_stderr, conn_set_stdout, conn_write - 3.1.02018-05-15 · diff ↗
- 3.0.32018-05-07 · diff ↗
- RR 3.5.0 released · 2018-04-23
- 2.0.0.12017-07-30 · diff ↗
- 2.0.02017-05-30
- RR 3.4.0 released · 2017-04-21
Package metadata
- First published
- 2017-05-30
- Total releases
- 30 / 9 yrs
- License
- MIT + file LICENSE OSI
- Minimum R
- ≥ 3.4.0
- Download size
- 191 KB
Cite
Cite this package
Run in R for the authors' preferred citation:
citation("processx")This package has no citation file, so citation() returns this entry built from DESCRIPTION.
Cite the R Observatory
For a number measured here: a download total, a coverage figure, an archival date.
From data release v2026-10-18, which the citation names so these numbers can be found later. More on citing and the projects behind them.