Skip to content

⬆️(deps): Bump github.com/swiftlang/swift-subprocess from 0.5.0 to 1.0.1 - #1332

Open
dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/swift/github.com/swiftlang/swift-subprocess-1.0.1
Open

dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/swift/github.com/swiftlang/swift-subprocess-1.0.1

Conversation

@dependabot

@dependabot dependabot Bot commented on behalf of github Oct 13, 2026

Copy link
Copy Markdown
Contributor

Bumps github.com/swiftlang/swift-subprocess from 0.5.0 to 1.0.1.

Release notes

Sourced from github.com/swiftlang/swift-subprocess's releases.

Subprocess 1.0.1 is a bug fix release with no API changes. Its biggest change is under the hood: on Linux and FreeBSD, Subprocess now launches processes with posix_spawn instead of fork/exec wherever the C library supports it, which makes launching a process cheaper, especially from a large, multithreaded process. This release also fixes a file descriptor leak in streamed output, closes a descriptor-inheritance race, and makes supplementaryGroups: [] do what it says.


posix_spawn is now preferred on every Unix platform (#365)

Through 1.0.0, Subprocess used posix_spawn only on Darwin. Every other Unix platform used fork followed by exec, in a second, near-duplicate implementation with its own copy of the executable search loop, the transient-failure retry, the file descriptor bookkeeping, and the error mapping. 1.0.1 merges the two into one shared implementation that prefers posix_spawn everywhere and falls back to fork/exec only for configurations posix_spawn can't express.

Using posix_spawn improves performance significantly when spawning child processes with a large memory footprint. fork() duplicates the calling process's entire address space. posix_spawn avoids that work by using clone(CLONE_VM | CLONE_VFORK) on Glibc and rfork(RFSPAWN) on FreeBSD.

Bug Fixes & Behavior Changes

  • Close .sequence output and error pipes when the body closure stops reading early (#369). SubprocessOutputSequence closed its pipe only when a read reached end-of-file, so breaking out of a for try await loop early leaked one file descriptor per run() call, without bound. run() now closes each .sequence stream exactly once after the body closure returns or throws, whether or not the stream was drained.
  • Create pipes and duplicate descriptors with close-on-exec set atomically (#373). Subprocess used to mark its pipes close-on-exec with a separate fcntl() after creating them, so a process launched from another thread in between could inherit a descriptor that wasn't marked yet. Pipes now come from pipe2(O_CLOEXEC) on Linux, Android, FreeBSD, and OpenBSD, and duplicates from F_DUPFD_CLOEXEC everywhere; Darwin keeps creating pipes the old way until its SDK declares pipe2.
  • supplementaryGroups: [] now drops inherited supplementary groups (#384). An empty array used to behave exactly like nil, so the new process kept the caller's supplementary groups; any non-nil value now calls setgroups(), and [] drops them all. This is a behavior change: an unprivileged process that sets supplementaryGroups = [] now fails with .spawnFailed (EPERM), as it already did for a non-empty list. Resolves #381.
  • Report the correct errno when posix_spawnattr setup fails on Darwin (#368). The thrown SubprocessError carried a leftover success code from an earlier call instead of the error from the failing posix_spawnattr_* call.
  • Make the CMake build suitable for Swift toolchain builds (#376). Prepare Subprocess to be used as a dependency in CMake builds.

Detailed Change Log

New Contributors

Full Changelog: swiftlang/swift-subprocess@1.0.0...1.0.1

Subprocess 1.0.0

Subprocess 1.0 is here. 🎉 This release marks an important milestone for this package: the advent of source stability!

Subprocess is a cross-platform package for spawning processes in Swift, supporting macOS, Linux, Windows, FreeBSD, OpenBSD, and Android. It was first pitched as SF-0007 and shipped as a public beta in spring 2025. A year of community feedback later, SF-0037 reviewed the accumulated API changes, and this release makes them final.

This note has two parts. If you last looked at Subprocess when it went through Swift Evolution, start with What Changed Since SF-0007. If you're already on 1.0.0-beta.1, skip to What Changed Since 1.0.0-beta.1.

... (truncated)

Commits

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [github.com/swiftlang/swift-subprocess](https://github.com/swiftlang/swift-subprocess) from 0.5.0 to 1.0.1.
- [Release notes](https://github.com/swiftlang/swift-subprocess/releases)
- [Commits](https://github.com/swiftlang/swift-subprocess/commits/1.0.1)

---
updated-dependencies:
- dependency-name: github.com/swiftlang/swift-subprocess
  dependency-version: 1.0.1
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot added the dependencies Update dependencies label Oct 13, 2026
@sonarqubecloud

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Update dependencies

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants