octokit / octokit.objc

GitHub API client for Objective-C
MIT License
1.84k stars 319 forks source link

Cannot fetchUserRepositories use the code. #276

Closed Janrin closed 5 years ago

Janrin commented 9 years ago

Code: OCTUser user = [OCTUser userWithRawLogin:@"Janrin" server:OCTServer.dotComServer]; OCTClient client = [OCTClient unauthenticatedClientWithUser:user]; RACSignal request = [client fetchUserRepositories]; [request subscribeNext:^(OCTRepository repository) { NSLog(@"%@", repository.name); } error:^(NSError *error) { NSLog(@"%@", error); } completed:^{ NSLog(@"done....."); }];

Console Log: 2015-08-22 14:58:27.467 Example[5234:471735] Error Domain=OCTClientErrorDomain Code=668 "Not Found" UserInfo=0x7ff872c685a0 {NSLocalizedDescription=Not Found, OCTClientErrorHTTPStatusCodeKey=404, OCTClientErrorRequestURLKey=https://api.github.com/users/(null)/repos?per_page=100, NSUnderlyingError=0x7ff872d29bb0 "Expected status code in (200-299,304), got 404"}

joshaber commented 9 years ago

Huh, that does indeed look like a bug.

+userWithRawLogin:server: should (probably?) set the login as well.

zackbraksa commented 8 years ago

Was this resolved ? I'm kinda experiencing the same issue ...