Kitura/Kitura-Sample

develop branch trying to 'make run' on OS X fails, Linux FINE

Closed this issue · 7 comments

Submodule 'Kitura-Build' (https://github.com/IBM-Swift/Kitura-Build.git) registered for path 'Kitura-Build'
Cloning into '/Users/swiftly/Kitura-Sample/Packages/Kitura/Kitura-Build'...
error: no such remote ref f7b5be7f7f89215eadeda03ef8c4b42356f9221a
Fetched in submodule path 'Kitura-Build', but it did not contain f7b5be7f7f89215eadeda03ef8c4b42356f9221a. Direct fetching of that commit failed.

That is the error I get on several Mac's trying to just run the sample project without any changes? If I run it as a vagrant build it works just fine?

@jtomchak I see that Kitura-Build is cloned into Packages/Kitura/Kitura-Build, while it should be cloned into Kitura-Sample. Are you running make run in /Users/swiftly/Kitura-Sample ?

For me fetching Kitura-Build works on Mac. Can you remove Kitura-Build from Kitura-Sample and run make run again? If it fails, can you paste here the whole output of make?

@vadimeisenbergibm I am running make run from /Users/swiftly/Kitura-Sample

Jesses-MacBook-Pro:Kitura-Sample swiftly$ rm -rf Kitura-Build/
Jesses-MacBook-Pro:Kitura-Sample swiftly$ make run
--- Fetching Kitura-Build submodule
git submodule init
git submodule update --remote --merge
Submodule path 'Kitura-Build': checked out 'a612f289903a6007fb80048bf3798d362deccf1c'
--- Running build on Darwin
--- Build scripts directory: Kitura-Build/build
--- Checking swift version
swift --version
Apple Swift version 3.0-dev (LLVM dffa09ffd8, Clang 1e6cba3ce3, Swift d2aee43220)
Target: x86_64-apple-macosx10.9
--- Checking swiftc version
swiftc --version
Apple Swift version 3.0-dev (LLVM dffa09ffd8, Clang 1e6cba3ce3, Swift d2aee43220)
Target: x86_64-apple-macosx10.9
--- Checking git revision and branch
git rev-parse HEAD
8f50a5c39259b0d1316b34b156dd40b3e461cf7d
git rev-parse --abbrev-ref HEAD
develop
--- Invoking swift build
swift build  
Resolved version: 0.17.6
Cloning https://github.com/IBM-Swift/Kitura-net.git
/usr/local/bin/git clone --recursive --depth 10 https://github.com/IBM-Swift/Kitura-net.git /Users/swiftly/Kitura-Sample/Packages/Kitura-net
Cloning into '/Users/swiftly/Kitura-Sample/Packages/Kitura-net'...
Submodule 'Kitura-Build' (https://github.com/IBM-Swift/Kitura-Build.git) registered for path 'Kitura-Build'
Cloning into '/Users/swiftly/Kitura-Sample/Packages/Kitura-net/Kitura-Build'...
error: no such remote ref d0d9d6c739a79627641e6438fe4f39bd0eba83bb
Fetched in submodule path 'Kitura-Build', but it did not contain d0d9d6c739a79627641e6438fe4f39bd0eba83bb. Direct fetching of that commit failed.

error: Failed to clone https://github.com/IBM-Swift/Kitura-net.git to /Users/swiftly/Kitura-Sample/Packages/Kitura-net
make: *** [build] Error 1

I also wanted to double, triple check that I had the right Swift toolchain,

Jesses-MacBook-Pro:Kitura-Sample swiftly$ xcrun --find swift
/Library/Developer/Toolchains/swift-DEVELOPMENT-SNAPSHOT-2016-05-03-a.xctoolchain/usr/bin/swift

The problem is with git clone --recursive. git clone is invoked by swift build.

/usr/local/bin/git clone --recursive --depth 10 https://github.com/IBM-Swift/Kitura-net.git

The errors you experience are git errors.

I guess you will get the same errors if you will run the same git command in the terminal. Can you try that command in some other directory? Can you paste here your version of git: git --version ?

I figured as much, I don't know enough about git submodules to investigate very well. Like why it can't find that particular ref commit hash?

Jesses-MacBook-Pro:~ swiftly$ /usr/local/bin/git clone --recursive --depth 10 https://github.com/IBM-Swift/Kitura-net.git
Cloning into 'Kitura-net'...
remote: Counting objects: 253, done.
remote: Compressing objects: 100% (142/142), done.
remote: Total 253 (delta 134), reused 188 (delta 86), pack-reused 0
Receiving objects: 100% (253/253), 63.28 KiB | 0 bytes/s, done.
Resolving deltas: 100% (134/134), done.
Checking connectivity... done.
Submodule 'Kitura-Build' (https://github.com/IBM-Swift/Kitura-Build.git) registered for path 'Kitura-Build'
Cloning into '/Users/swiftly/Kitura-net/Kitura-Build'...
error: no such remote ref d0d9d6c739a79627641e6438fe4f39bd0eba83bb
Fetched in submodule path 'Kitura-Build', but it did not contain d0d9d6c739a79627641e6438fe4f39bd0eba83bb. Direct fetching of that commit failed.
Jesses-MacBook-Pro:~ swiftly$ git --version
git version 2.9.0
Jesses-MacBook-Pro:~ swiftly$ 

The problem is with git version 2.9.0, which was released 5 days ago. I have submitted a bug report to git:
http://marc.info/?l=git&m=146632066932159&w=2

Please try a previous git version.

Oh man. Downgraded to 2.7.4 and it works fine. Thanks for helping out. I would have never figured that out.