Skip to content

builtArtifact empty when building a target from dependencies #9119

@supersonicbyte

Description

@supersonicbyte

Is it reproducible with SwiftPM command-line tools: swift build, swift test, swift package etc?

  • Confirmed reproduction steps with SwiftPM CLI. The description text must include reproduction steps with either of command-line SwiftPM commands, swift build, swift test, swift package etc.

Description

I believe that a38e1d6 introduced a regression where when building a product from a dependency will return empty build artifacts.

Here is an example repo: https://github.com/supersonicbyte/plugin-package-manager-build

When we try to invoke the command plugin inside the LocalPackages/Client directory built artifacts will be [] after this commit. On versions before this commit everything works as expected.

Expected behavior

The build artifcats not to be empty.

Actual behavior

The build artifact array is empty.

Steps to reproduce

  1. Clone repo: https://github.com/supersonicbyte/plugin-package-manager-build
  2. cd LocalPackages/Client
  3. swift package plugin_package_manager_build

Swift Package Manager version/commit hash

No response

Swift & OS version (output of swift --version ; uname -a)

swift-driver version: 1.120.5 Apple Swift version 6.1.2 (swiftlang-6.1.2.1.2 clang-1700.0.13.5)
Target: arm64-apple-macosx15.0
Darwin Mac 24.6.0 Darwin Kernel Version 24.6.0: Mon Jul 14 11:28:30 PDT 2025; root:xnu-11417.140.69~1/RELEASE_ARM64_T6030 arm64

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions