Skip to content

Revert "missing pinned version" change for 5.10 #6883

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 12, 2023

Conversation

neonichu
Copy link
Contributor

There's an unfortunate interaction here with the resolver precomputation / LocalPackageContainer which leads to us rejecting versions as "not available" if they don't happen to be the currently checked out version. We need a more hollistic change to resolve this issue which is out of scope for 5.9, so we'll revert this change here.

rdar://115303494

(cherry picked from commit 87d65e3)

There's an unfortunate interaction here with the resolver precomputation / `LocalPackageContainer` which leads to us rejecting versions as "not available" if they don't happen to be the currently checked out version. We need a more hollistic change to resolve this issue which is out of scope for 5.9, so we'll revert this change here.

rdar://115303494

(cherry picked from commit 87d65e3)
@neonichu neonichu added the swift 5.10 This PR targets the 5.10 branch label Sep 11, 2023
@neonichu neonichu requested a review from tomerd as a code owner September 11, 2023 18:50
@neonichu neonichu self-assigned this Sep 11, 2023
@neonichu
Copy link
Contributor Author

@swift-ci please test

@neonichu
Copy link
Contributor Author

stderr: error: 'validlayouts_singlemodule_library': Invalid manifest (compiled with: ["/Users/ec2-user/jenkins/workspace/swift-package-manager-PR-macos-smoke-test/branch-main/build/buildbot_incremental/toolchain-macosx-x86_64/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swiftc", "-vfsoverlay", "/var/folders/7n/r31lzfjx6556jgc6vg55_cg80000gn/T/TemporaryDirectory.3kz842/vfs.yaml", "-L", "/Users/ec2-user/jenkins/workspace/swift-package-manager-PR-macos-smoke-test/branch-main/build/buildbot_incremental/swiftpm-macosx-x86_64/x86_64-apple-macosx/lib/swift/pm/ManifestAPI", "-lPackageDescription", "-Xlinker", "-rpath", "-Xlinker", "/Users/ec2-user/jenkins/workspace/swift-package-manager-PR-macos-smoke-test/branch-main/build/buildbot_incremental/swiftpm-macosx-x86_64/x86_64-apple-macosx/lib/swift/pm/ManifestAPI", "-target", "x86_64-apple-macosx12.0", "-sdk", "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.1.sdk", "-F", "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", "-I", "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib", "-L", "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib", "-swift-version", "4.2", "-I", "/Users/ec2-user/jenkins/workspace/swift-package-manager-PR-macos-smoke-test/branch-main/build/buildbot_incremental/swiftpm-macosx-x86_64/x86_64-apple-macosx/lib/swift/pm/ManifestAPI", "-sdk", "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.1.sdk", "-package-description-version", "4.2.0", "-module-cache-path", "/Users/ec2-user/jenkins/workspace/swift-package-manager-PR-macos-smoke-test/branch-main/build/buildbot_incremental/swiftpm-macosx-x86_64/x86_64-apple-macosx/release", "/private/var/folders/7n/r31lzfjx6556jgc6vg55_cg80000gn/T/ValidLayouts_SingleModule_Library.qHAdt5/ValidLayouts_SingleModule_Library/Package.swift", "-Xfrontend", "-disable-implicit-concurrency-module-import", "-Xfrontend", "-disable-implicit-string-processing-module-import", "-o", "/var/folders/7n/r31lzfjx6556jgc6vg55_cg80000gn/T/TemporaryDirectory.wTS7Pb/validlayouts_singlemodule_library-manifest"])
<unknown>:0: error: cannot open file '/private/var/folders/7n/r31lzfjx6556jgc6vg55_cg80000gn/T/spm-tests-testInitPackageLibrary.BWg1TC/Foo/.build/x86_64-apple-macosx/debug/Foo.build/module.modulemap' (No such file or directory)
/private/var/folders/7n/r31lzfjx6556jgc6vg55_cg80000gn/T/ValidLayouts_SingleModule_Library.qHAdt5/ValidLayouts_SingleModule_Library/Package.swift:1:8: error: failed to build module 'Foundation'; this SDK is not supported by the compiler (the SDK is built with 'Apple Swift version 5.7.1 (swiftlang-5.7.1.134.4 clang-1400.0.29.51)', while this compiler is 'Apple Swift version 5.9-dev (LLVM 4ebee5bc182ee86, Swift 5b8553cbe76b51b)'). Please select a toolchain which matches the SDK.
import Foundation
       ^

@tomerd
Copy link
Contributor

tomerd commented Sep 11, 2023

the PR is into "main", did you mean to make into "5.10"?

@neonichu neonichu changed the base branch from main to release/5.10 September 11, 2023 20:39
@neonichu
Copy link
Contributor Author

the PR is into "main", did you mean to make into "5.10"?

Yes, good catch.

@neonichu
Copy link
Contributor Author

@swift-ci please test

@neonichu
Copy link
Contributor Author

FAIL: Swift(windows-x86_64) :: Driver/windows-link-job.swift (2265 of 9746)
******************** TEST 'Swift(windows-x86_64) :: Driver/windows-link-job.swift' FAILED ********************
Script:
--
: 'RUN: at line 1';   rm -rf "T:\1\tools\swift\test-windows-x86_64\Driver\Output\windows-link-job.swift.tmp/DISTINCTIVE-WINDOWS-PATH/usr/bin" && mkdir -p "T:\1\tools\swift\test-windows-x86_64\Driver\Output\windows-link-job.swift.tmp/DISTINCTIVE-WINDOWS-PATH/usr/bin"
: 'RUN: at line 2';   rm -rf "T:\1\tools\swift\test-windows-x86_64\Driver\Output\windows-link-job.swift.tmp/DISTINCTIVE-WINDOWS-PATH/usr/lib" && mkdir -p "T:\1\tools\swift\test-windows-x86_64\Driver\Output\windows-link-job.swift.tmp/DISTINCTIVE-WINDOWS-PATH/usr/lib"
: 'RUN: at line 3';   ln 't:\\1\\bin\\swift-frontend.exe' T:\1\tools\swift\test-windows-x86_64\Driver\Output\windows-link-job.swift.tmp/DISTINCTIVE-WINDOWS-PATH/usr/bin/swiftc || cp 't:\\1\\bin\\swift-frontend.exe' T:\1\tools\swift\test-windows-x86_64\Driver\Output\windows-link-job.swift.tmp/DISTINCTIVE-WINDOWS-PATH/usr/bin/swiftc
: 'RUN: at line 4';   env PATH= T:\1\tools\swift\test-windows-x86_64\Driver\Output\windows-link-job.swift.tmp/DISTINCTIVE-WINDOWS-PATH/usr/bin/swiftc -target x86_64-unknown-windows-msvc -### -module-name link -emit-library C:\Users\swift-ci\jenkins\workspace\swiftpm-PR-windows\swift\test\Driver\windows-link-job.swift 2>&1 | "C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python37_64\python.exe" C:\Users\swift-ci\jenkins\workspace\swiftpm-PR-windows\swift\utils\PathSanitizingFileCheck --allow-unused-prefixes --sanitize BUILD_DIR=T:/1/tools/swift --sanitize SOURCE_DIR=C:/Users/swift-ci/jenkins/workspace/swiftpm-PR-windows/swift --use-filecheck t:\1\bin\filecheck.exe --enable-windows-compatibility C:\Users\swift-ci\jenkins\workspace\swiftpm-PR-windows\swift\test\Driver\windows-link-job.swift
--
Exit Code: 1

Command Output (stdout):
--
$ ":" "RUN: at line 1"
$ "rm" "-rf" "T:\1\tools\swift\test-windows-x86_64\Driver\Output\windows-link-job.swift.tmp/DISTINCTIVE-WINDOWS-PATH/usr/bin"
# command stderr:
Error: 'rm' command failed, [WinError 32] The process cannot access the file because it is being used by another process.
error: command failed with exit status: 1

@neonichu
Copy link
Contributor Author

@swift-ci please test windows

@neonichu neonichu merged commit cd27b44 into release/5.10 Sep 12, 2023
@neonichu neonichu deleted the revert-fix_missing_pinned_version-5.10 branch September 12, 2023 16:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
swift 5.10 This PR targets the 5.10 branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants