FatFractal customer forums



Author Topic: Registering New User: Error 1  (Read 629 times)

metakite

  • Jr. Member
  • **
  • Posts: 54
    • View Profile
Registering New User: Error 1
« on: September 11, 2015, 03:04:32 PM »
I'm trying to spin up a new app, and I think I might have something configured incorrectly in my FatFractal NoServer installation.

I'm trying to use the iOS SDK to register a new user with this FatFractal method:

Code: [Select]
- (void) registerUser:(id<FFUserProtocol>)user password:(NSString *)password onComplete:(FFHttpMethodCompletion)onComplete;
When I do, I get back an error:
Code: [Select]
Error Domain=FatFractal
Error Code=1
Localized Description="HTTP POST returned no data, but no error was set ..."

I can't really tell what's wrong from reading the reported error message, so I am hoping that you can clue me in.

For your reference, here is my app info:
subdomain: metakite
app: metatax

And below are the contents of my Xcode console log when I enable debug logging in the FatFractal SDK:
Code: [Select]
2015-09-11 14:52:03.304 MetaTax[60801:9521265] Reachability Flag Status: -R -----l- networkStatusForFlags
2015-09-11 14:52:03.307 MetaTax[60801:9521265] Application URL: https://metakite.fatfractal.com/metakite
2015-09-11 14:52:03.308 MetaTax[60801:9521631] Loading queued operations from local storage
2015-09-11 14:52:03.308 MetaTax[60801:9521631] No local queued operation store found!
2015-09-11 14:52:38.819 MetaTax[60801:9521265] Reachability Flag Status: -R -----l- networkStatusForFlags
2015-09-11 14:52:38.819 MetaTax[60801:9521265] Attempting to register new user FFUser[ guid[(null)] active[0], userName[test],firstName[(null)],lastName[(null)],email[charles@metakite.com], authDomain[(null)], scriptAuthService[(null)], groupsLoaded[0],groups[{
}]] to https://metakite.fatfractal.com/metakite/ff/register
2015-09-11 14:52:38.820 MetaTax[60801:9521265] getClazzFromClass:FFUser returning FFUser
2015-09-11 14:52:38.820 MetaTax[60801:9521265] classToClazzDict is {
}
2015-09-11 14:52:38.820 MetaTax[60801:9521265] dictionaryFromObject: Got property attributes T@"NSString",&,N,VlastName for key lastName
2015-09-11 14:52:38.821 MetaTax[60801:9521265] dictionaryFromObject: Setting [NSNull null] for lastName
2015-09-11 14:52:38.821 MetaTax[60801:9521265] dictionaryFromObject: Got property attributes T@"NSString",&,N,Vguid for key guid
2015-09-11 14:52:38.821 MetaTax[60801:9521265] dictionaryFromObject: Setting [NSNull null] for guid
2015-09-11 14:52:38.821 MetaTax[60801:9521265] dictionaryFromObject: Got property attributes T@"NSString",&,N,VfirstName for key firstName
2015-09-11 14:52:38.830 MetaTax[60801:9521265] dictionaryFromObject: Setting [NSNull null] for firstName
2015-09-11 14:52:38.830 MetaTax[60801:9521265] dictionaryFromObject: Got property attributes Tc,N,Vactive for key active
2015-09-11 14:52:38.831 MetaTax[60801:9521265] dictionaryFromObject: Got property attributes T@"NSString",&,N,VauthDomain for key authDomain
2015-09-11 14:52:38.831 MetaTax[60801:9521265] dictionaryFromObject: Setting [NSNull null] for authDomain
2015-09-11 14:52:38.831 MetaTax[60801:9521265] dictionaryFromObject: Got property attributes T@"NSString",&,N,VuserName for key userName
2015-09-11 14:52:38.831 MetaTax[60801:9521265] dictionaryFromObject: Got property attributes T@"NSString",&,N,Vemail for key email
2015-09-11 14:52:38.831 MetaTax[60801:9521265] dictionaryFromObject: Got property attributes T@"NSString",&,N,VscriptAuthService for key scriptAuthService
2015-09-11 14:52:38.831 MetaTax[60801:9521265] dictionaryFromObject: Setting [NSNull null] for scriptAuthService
2015-09-11 14:52:38.839 MetaTax[60801:9521265] metaDataForObj: Did not find in-memory metadata for object FFUser[ guid[(null)] active[0], userName[test],firstName[(null)],lastName[(null)],email[charles@metakite.com], authDomain[(null)], scriptAuthService[(null)], groupsLoaded[0],groups[{
}]]
2015-09-11 14:52:38.839 MetaTax[60801:9521265] dictionaryFromObject created dictionary {
    active = 0;
    authDomain = "<null>";
    clazz = FFUser;
    email = "charles@metakite.com";
    firstName = "<null>";
    guid = "<null>";
    lastName = "<null>";
    scriptAuthService = "<null>";
    userName = test;
} from object FFUser[ guid[(null)] active[0], userName[test],firstName[(null)],lastName[(null)],email[charles@metakite.com], authDomain[(null)], scriptAuthService[(null)], groupsLoaded[0],groups[{
}]]
2015-09-11 14:52:38.839 MetaTax[60801:9521265] invokeHttpMethod: Will send HTTP POST to url: https://metakite.fatfractal.com/metakite/ff/register in thread <NSThread: 0x78894440>{number = 1, name = main}
2015-09-11 14:52:38.861 MetaTax[60801:9521265] invokeHttpMethod:

HTTP request body (pretty-print):

{
  "clazz" : "FFUser",
  "lastName" : null,
  "guid" : null,
  "firstName" : null,
  "password" : "thePassword",
  "active" : false,
  "authDomain" : "LOCAL",
  "userName" : "test",
  "email" : "charles@metakite.com",
  "scriptAuthService" : null
}

2015-09-11 14:52:38.864 MetaTax[60801:9521265] Started (from main thread <NSThread: 0x78894440>{number = 1, name = main}) NSURLConnection for POST to https://metakite.fatfractal.com/metakite/ff/register
2015-09-11 14:52:38.996 MetaTax[60801:9521265] canAuthenticateAgainstProtectionSpace <NSURLProtectionSpace: 0x78b39ce0>: Host:metakite.fatfractal.com, Server:https, Auth-Scheme:NSURLAuthenticationMethodServerTrust, Realm:(null), Port:443, Proxy:NO, Proxy-Type:(null) called
2015-09-11 14:52:39.128 MetaTax[60801:9521265] FFHttpDelegate calling onComplete for POST to https://metakite.fatfractal.com/metakite/ff/register from main thread <NSThread: 0x78894440>{number = 1, name = main}

metakite

  • Jr. Member
  • **
  • Posts: 54
    • View Profile
Re: Registering New User: Error 1
« Reply #1 on: September 11, 2015, 04:43:21 PM »
Gary helped me offline and found my problem.

For the benefit of anyone who comes after me, this error was a result of initializing the FatFractal object with the wrong base URL. A simple typo.

Thanks Gary!

 

Copyright © FatFractal customer forums