-
Notifications
You must be signed in to change notification settings - Fork 66
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
Test with Xcode 8 beta #280
Comments
Do you have an estimate on when you'll support Xcode 8? I'm trying locally and getting the following error:
|
Hi @thalmicMark, can you please make sure you're using the latest version of Buildasaur? I fixed some issues with JSON parsing in 1.0.1. If it still persists, I'll take a deeper look. Thanks! |
Yeah, I'm on |
Ok. I just ran Buildasaur with Xcode Server running Xcode 8 and things worked. Can you tell me your exact setup: Server.app, Xcode versions, maybe even exact steps? |
Buildasaur: I installed Server beta 3, and when selecting the beta version of Xcode 8, Server prompted me to create an Xcode Server user account. Once that account was created, Xcode Server was able to run my bots. Since I installed Server beta 3, my Buildasaur syncer has been displaying the above error. Are there any more specific logs I can send you from Buildasaur? I'm guessing the Xcode Server API might have changed. |
Found this in the logs:
|
I've also got the JSON response from my server that is causing the error (response from |
Yes please, czechboy0 at gmail
|
@thalmicMark @czechboy0 I'm getting the same error with Xcode 7.3.1, Buildasar 1.0.2, Server 5.1.5. Is there any solution to this?
|
I guess the logging for missing keys could be tweaked a bit. It looks like as of Beta 6 trigger conditions don't contain the Workaround, patch
|
@flufff42 Could you please PR a fix for that in XcodeServer? https://github.com/czechboy0/XcodeServerSDK/blob/1bdcf1af67007123d25e2e73504935c46084bb08/XcodeServerSDK/Server%20Entities/TriggerConditions.swift#L55 We can just use it if it's there, give |
Sounds good, I've opened buildasaurs/XcodeServerSDK#140 in place. |
When can we expect a release with buildasaurs/XcodeServerSDK#140 included? I saw it was just merged. |
@thalmicMark @flufff42 Here's a release with the fix: https://github.com/czechboy0/XcodeServerSDK/releases/tag/v0.7.1 It's also in master of Buildasaur, just pull from there and run |
@czechboy0 Is there any change there'll be a new Buildasar.app to download? I'm having a lot off issues building. Every step I get to I end up having to debug and I finally get past it only to run into another issue: Currently, it's Installing ReactiveCocoa (4.0.1)
[!] /bin/bash -c
set -e
sed -i '' 's@<ReactiveCocoa/\(.*\)>@"\1"@g' ReactiveCocoa/ReactiveCocoa.h
sed: can't read s@<ReactiveCocoa/\(.*\)>@"\1"@g: No such file or directory UPDATE: solved that by changing the pod to look at version |
@tettoffensive Can you try 1. delete the Pods folder, 2. ensure your cocoapods version is 1.0.1, 3. run pod install again? This exact sequence worked fine for me. |
I'd like an official Buildasaur.app as well, otherwise I'd need to create my own GitHub API keys. If the timeline for an app is too long, we'll go down the custom key road, but I'd like to avoid it. |
@czechboy0 I managed to build by changing the ReactiveCocoa pod version to Now, I'm running the master version of Buildasaur, but I still get the same error.
|
public class Bot : XcodeServerEntity {
public let name: String
public let configuration: BotConfiguration
public let integrationsCount: Int
public required init(json: NSDictionary) throws {
self.name = try json.stringForKey("name") // json error thrown. "name" not found. (lldb) bt
* thread #1: tid = 0xabfe53, 0x00000001010c4ed0 libswiftCore.dylib`swift_willThrow, queue = 'com.apple.main-thread', stop reason = breakpoint 3.1
frame #0: 0x00000001010c4ed0 libswiftCore.dylib`swift_willThrow
* frame #1: 0x0000000100461700 BuildaUtils`NSDictionary.nonOptionalForKey<A> (key="name", self=3 key/value pairs, $error=ErrorType @ 0x00007fff5fbfcb28) throws -> A + 608 at JSON.swift:83
frame #2: 0x0000000100461e26 BuildaUtils`NSDictionary.stringForKey(key="name", self=3 key/value pairs, $error=ErrorType @ 0x00007fff5fbfcb28) throws -> String + 102 at JSON.swift:108
frame #3: 0x0000000100461f0b BuildaUtils`@objc NSDictionary.stringForKey(String) throws -> String + 91 at JSON.swift:0
frame #4: 0x0000000100a4e7d1 XcodeServerSDK`Bot.init(json=3 key/value pairs, $error=ErrorType @ 0x00007fff5fbfce50) throws -> Bot + 129 at Bot.swift:19
frame #5: 0x0000000100a4e6ab XcodeServerSDK`Bot.__allocating_init($error=ErrorType @ 0x00007fff5fbfce50) throws -> Bot + 75 at Bot.swift:0
frame #6: 0x0000000100a9ca33 XcodeServerSDK`XcodeServer.(dictBody=3 key/value pairs, $error=ErrorType @ 0x00007fff5fbfce50)(Bot, completion : (response : XcodeServer.CreateBotResponse) -> ()) -> ()).(closure #1).(closure #1) + 67 at XcodeServer+Bot.swift:213
frame #7: 0x0000000100a9b657 XcodeServerSDK`thunk + 39 at XcodeServer+Bot.swift:0
frame #8: 0x0000000100a9a131 XcodeServerSDK`partial apply for thunk + 81 at XcodeServer+Bot.swift:0
frame #9: 0x000000010045a356 BuildaUtils`unthrow<A> (block=0x0000000100a9a0e0 XcodeServerSDK`partial apply forwarder for reabstraction thunk helper from @callee_owned () -> (@owned XcodeServerSDK.Bot, @error @owned Swift.ErrorType) to @callee_owned () -> (@out XcodeServerSDK.Bot, @error @owned Swift.ErrorType) with unmangled suffix ".25" at XcodeServer+Bot.swift) throws -> A) -> (A?, NSError?) + 166 at Extensions.swift:21
frame #10: 0x0000000100a9c68d XcodeServerSDK`XcodeServer.(response=0x000060800022ece0, body=Some, error=nil, completion=0x0000000100beee60 BuildaKit`partial apply forwarder for static BuildaKit.XcodeServerSyncerUtils.(createBotFromBuildTemplate (Swift.String, syncer : BuildaKit.StandardSyncer, template : BuildaKit.BuildTemplate, project : BuildaKit.Project, branch : Swift.String, scheduleOverride : Swift.Optional<XcodeServerSDK.BotSchedule>, xcodeServer : XcodeServerSDK.XcodeServer, completion : (bot : Swift.Optional<XcodeServerSDK.Bot>, error : Swift.Optional<__ObjC.NSError>) -> ()) -> ()).(closure #1) at XcodeServerSyncerUtils.swift)(Bot, completion : (response : XcodeServer.CreateBotResponse) -> ()) -> ()).(closure #1) + 589 at XcodeServer+Bot.swift:214
frame #11: 0x0000000100ab1a58 XcodeServerSDK`XcodeServer.(response=0x000060800022ece0, body=Some, error=nil, completion=0x0000000100a99fc0 XcodeServerSDK`partial apply forwarder for XcodeServerSDK.XcodeServer.((createBotNoValidation in _C0122213F3E9259288EB5FBCD97EEB0B) (XcodeServerSDK.Bot, completion : (response : XcodeServerSDK.XcodeServer.CreateBotResponse) -> ()) -> ()).(closure #1) at XcodeServer+Bot.swift, self=0x00006000001421b0) -> ()) -> NSURLSessionTask?).(closure #1) + 1848 at XcodeServer.swift:145
frame #12: 0x000000010045e6bb BuildaUtils`HTTP.(data=328 bytes, response=0x000060800022ece0, error=nil, completion=0x0000000100ab0ec0 XcodeServerSDK`partial apply forwarder for XcodeServerSDK.XcodeServer.(sendRequestWithMethod (BuildaUtils.HTTP.Method, endpoint : XcodeServerSDK.XcodeServerEndpoints.Endpoint, params : Swift.Optional<Swift.Dictionary<Swift.String, Swift.String>>, query : Swift.Optional<Swift.Dictionary<Swift.String, Swift.String>>, body : Swift.Optional<__ObjC.NSDictionary>, portOverride : Swift.Optional<Swift.Int>, completion : (response : Swift.Optional<__ObjC.NSHTTPURLResponse>, body : Swift.Optional<Swift.AnyObject>, error : Swift.Optional<__ObjC.NSError>) -> ()) -> Swift.Optional<__ObjC.NSURLSessionTask>).(closure #1) at XcodeServer.swift) -> ()) -> NSURLSessionTask).(closure #1) + 2507 at HTTPUtils.swift:63
frame #13: 0x000000010045f007 BuildaUtils`thunk + 103 at HTTPUtils.swift:0
frame #14: 0x00007fff9a8217f1 CFNetwork`__75-[__NSURLSessionLocal taskForClass:request:uploadFile:bodyData:completion:]_block_invoke + 21
frame #15: 0x00007fff9a8210bf CFNetwork`__49-[__NSCFLocalSessionTask _task_onqueue_didFinish]_block_invoke + 302
frame #16: 0x00007fff8d1bd7d7 Foundation`__NSBLOCKOPERATION_IS_CALLING_OUT_TO_A_BLOCK__ + 7
frame #17: 0x00007fff8d1bd495 Foundation`-[NSBlockOperation main] + 100
frame #18: 0x00007fff8d1bbb7a Foundation`-[__NSOperationInternal _start:] + 654
frame #19: 0x00007fff8d1b7b64 Foundation`__NSOQSchedule_f + 194
frame #20: 0x0000000101413cc5 libdispatch.dylib`_dispatch_client_callout + 8
frame #21: 0x000000010142b6ae libdispatch.dylib`_dispatch_main_queue_callback_4CF + 2845
frame #22: 0x00007fff8fa189e9 CoreFoundation`__CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 9
frame #23: 0x00007fff8f9d78dd CoreFoundation`__CFRunLoopRun + 1949
frame #24: 0x00007fff8f9d6ed8 CoreFoundation`CFRunLoopRunSpecific + 296
frame #25: 0x00007fff9af97935 HIToolbox`RunCurrentEventLoopInMode + 235
frame #26: 0x00007fff9af9776f HIToolbox`ReceiveNextEventCommon + 432
frame #27: 0x00007fff9af975af HIToolbox`_BlockUntilNextEventMatchingListInModeWithFilter + 71
frame #28: 0x00007fff869c1efa AppKit`_DPSNextEvent + 1067
frame #29: 0x00007fff869c132a AppKit`-[NSApplication _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 454
frame #30: 0x00007fff869b5e84 AppKit`-[NSApplication run] + 682
frame #31: 0x00007fff8697f46c AppKit`NSApplicationMain + 1176
frame #32: 0x00000001000c0964 Buildasaur`main + 84 at AppDelegate.swift:25
frame #33: 0x00007fff8d1625ad libdyld.dylib`start + 1 |
@tettoffensive whoa, that looks like Bots don't have a |
@czechboy0 |
You can check the raw JSON here |
@thalmicMark @czechboy0 so it turns out the call is returning 400. weird because i get a valid json response in the browser. |
tried changing my xcode server to "Bots can be created and viewed by: all users" on "all networks", but still a 400 :( |
i did a little debugging: private func createBotNoValidation(botOrder: Bot, completion: (response: CreateBotResponse) -> ()) {
let body: NSDictionary = botOrder.dictionarify()
let data: NSData?
do {
data = try NSJSONSerialization.dataWithJSONObject(body, options: NSJSONWritingOptions(rawValue: 0))
} catch _ {
data = nil
}
if (data != nil) {
print(NSString(data: data!, encoding: NSUTF8StringEncoding))
} used the json output and put that into Paw. and found that the |
Tried setting up Buildasaur fresh with Xcode 8 and got stuck on the page to create a new Build Template. I just get the endless spinner in the top left. I looked briefly in the code and it seems to be stuck waiting for a response from the XcodeServer API or the response was invalid. I tried pulling the project to build it myself to see if I could debug things a little more but I already updated to macOS Sierra and can't run Xcode 7 anymore (without some hacks). I tried getting the project building with Xcode 8 and Swift 2.3 but quite a few deps needed to be updated. I am willing to help migrate and get things running in Xcode 8 but it will be a lengthy process. I also am getting this in the logs:
Not sure why though cause it is a GitHub URL |
@kdawgwilk You may want to create a new issue for this and detail your exact setup. Xcode 8 has been out for a little while now and you seem to be the first to report this particular issue. |
Let's find out how we're doing with the new Xcode.
The text was updated successfully, but these errors were encountered: