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
I don't know if it could be interesting to provide default values to these parameters for these Run with Closure family of APIs, or if this is intended.
Then, the body of the closure in itself doesn't build, especially this line:
but I don't know if it's correct, I'm not yet familiar with the new ~Escapable capabilities and RawSpac introduced in Swift 6.2...
Finally, with this extension, it built fine but when I tried to run it, I got this runtime issue:
dyld[3790]: Symbol not found: _$ss7RawSpanVN
So, sorry for the long text, and for the multiple issues, the library looks really cool though and I would be glad to help if some of my modifications made sense!
Thanks for your help!
The text was updated successfully, but these errors were encountered:
Describe the bug
The sample code provided in Run with Custom Closure section (requiring
SubprocessSpan
trait) is not compiling.To Reproduce
Steps to reproduce the behavior:
swiftly
swift package init --type executable
swift-subprocess
a dependency & provide theSubprocessSpan
traitExpected behavior
It compiles and runs fine.
Environment (please complete the following information):
Additional context
I had trouble running the sample code provided in Run with Custom Closure section.
First, pls correct me if I'm wrong: I think we should specify that this sample would work only if you specify the
SubprocessSpan
trait.Then, even with the trait enabled, you have to provide these arguments to the
run
function:I don't know if it could be interesting to provide default values to these parameters for these Run with Closure family of APIs, or if this is intended.
Then, the body of the closure in itself doesn't build, especially this line:
withUnsafeBytes
is not available whenSubprocessSpan
is set.If you change it to:
then you get the following error: Lifetime-dependent value escapes its scope.
What's funny though is that I first tried to run this on Asahi Linux Fedora 42 and it worked fine (I didn't get the lifetime value error).
To circumvent this lifetime error on macOS (it wasn't needed on Linux), I added this extension:
but I don't know if it's correct, I'm not yet familiar with the new
~Escapable
capabilities andRawSpac
introduced in Swift 6.2...Finally, with this extension, it built fine but when I tried to run it, I got this runtime issue:
dyld[3790]: Symbol not found: _$ss7RawSpanVN
So, sorry for the long text, and for the multiple issues, the library looks really cool though and I would be glad to help if some of my modifications made sense!
Thanks for your help!
The text was updated successfully, but these errors were encountered: