You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If a target has a dependency on binaryTarget. Then the call of PackageManager.getSymbolGraph to that target will get a directory contains no symbol graph.
It will break PackageManager.getSymbolGraph's client such as swift-docc-plugin.
The downstream user can generate doc using swift build and call docc convert to generate documentation. But if they migrate to swift-docc-plugin or swift-docc-plugin based service like SwiftPackageIndex, the documentation build will fail.
Call swift-symbolgraph-extract with the arguments manually in terminal or adding the following patch to SymbolGraphExtract.swift
public func extractSymbolGraph(
...
try process.launch()
- try process.waitUntilExit()+ let result = try process.waitUntilExit()+ if let error = String(bytes: try result.stderrOutput.get(), encoding: .utf8) {+ print(error)+. }
}
And you will get the following error message.
"<unknown>:0: error: missing required module \'MMKV\'\nError: Failed to load the module \'DemoKit\'. Are you missing build dependencies or include/framework directories?\nSee the previous error messages for details. Aborting.\n"
I have tried to add the framework manually via -F/-I/-L ${MMKV_framework_path} but none of them will work.
Steps to reproduce
For user side reproduce steps:
Download the following DemoKit.zip package
Run swift package generate-documentation --target DemoKit --verbose and no documentation will be created.
For swiftpm developer reproduce steps:
Set up swiftpm repo development environment
Build PackageDescription target first and then choose swift-package target
Set working directory to DemoKit and the corresponding arguments on launch in Xcode
4.(Optional) Apply the diff mentioned above.
Is this an expected unimplemented feature or a bug we should fix? Checking the repository's Git history, I believe @MaxDesiatov would have some insights on this scope. Could you help give a look at this? Thanks
Is it reproducible with SwiftPM command-line tools:
swift build
,swift test
,swift package
etc?Description
If a target has a dependency on binaryTarget. Then the call of
PackageManager.getSymbolGraph
to that target will get a directory contains no symbol graph.It will break
PackageManager.getSymbolGraph
's client such as swift-docc-plugin.The downstream user can generate doc using
swift build
and calldocc convert
to generate documentation. But if they migrate to swift-docc-plugin or swift-docc-plugin based service like SwiftPackageIndex, the documentation build will fail.Expected behavior
Produce SymbolGraph normally.
Actual behavior
Call swift-symbolgraph-extract with the arguments manually in terminal or adding the following patch to SymbolGraphExtract.swift
And you will get the following error message.
I have tried to add the framework manually via
-F
/-I
/-L ${MMKV_framework_path}
but none of them will work.Steps to reproduce
For user side reproduce steps:
swift package generate-documentation --target DemoKit --verbose
and no documentation will be created.For swiftpm developer reproduce steps:
swift-package
targetDemoKit
and the corresponding arguments on launch in Xcode4.(Optional) Apply the diff mentioned above.
DemoKit.zip
Swift Package Manager version/commit hash
5.10
Swift & OS version (output of
swift --version ; uname -a
)5.10 & macOS 14.4.1
The text was updated successfully, but these errors were encountered: