Windows Bugs in SwiftPM

I just reported SR‐14577, SR‐14578 and SR‐14579, which are Windows‐specific bugs that have a rather sweeping effect on SwiftPM’s usability. I started looking into fixing each of them, but it seems all three are either over my head or else it is not clear to me where the fix properly belongs.

IIRC, location of XCTest should be added to the PATH environment variable.

For the dynamic loader to locate it at runtime, yes. But that is not the issue here. To my knowledge, SwiftPM does not (and should not) add Path entries to the importer search paths. In any case, it was properly registered in Path when I encountered the problem (SR‐14579). It is more likely that SwiftPM or the Swift driver has not yet been taught the standard location of XCTest, or that in contrast to other platforms the search path is only being added to test targets. I just do not know which component is supposed to be responsible for that.

SR-14577 seems to be a Unicode issue. I would recommend that for the time being you use ascii filenames. That is something that requires a pretty large change to SPM to fix.

SR-14578 should already be fixed in the 5.5 snapshots.

SR-14579 needs additional information. There is nothing to go upon there, and XCTest based test most definitely works, I've been using it for months locally and in GitHub Actions. I suspect that something is not setup properly (likely your environment variables). In particular, SPM's XCTest handling requires that DEVELOPER_DIR is setup properly.

Terms of Service

Privacy Policy

Cookie Policy