title: Issues with Firebase Analytics and iOS App
body: <p>I am running a demo project on XCode Version 8.2.1 and developing with with Swift 3.0. </p>
  
  <p>Normally, I do not use Cocoapods but decided to give it a try for the sake of learning. </p>
  
  <p>I used the the steps listed in the <a href="https://firebase.google.com/docs/ios/setup" rel="noreferrer">Official Firebase Get Started Tutorial for iOS</a> </p>
  
  <p>I was pretty much successful in achieving what the aforementioned guide outlines. </p>
  
  <p>My main intention to install Firebase was to use Analytics. As a starting project. I wanted to track which buttons are being pressed and then take it from there. </p>
  
  <p>As you can imagine I am having great difficulty getting the button tap(events) to reflect in my Firebase console. </p>
  
  <p>Heres the log from the console: </p>
  
  <pre><code>[Firebase/Analytics][I-ACS023007] Firebase Analytics v.40100000 started
  [Firebase/Analytics][I-ACS023008] To disable debug logging set the following application argument: -noFIRAnalyticsDebugEnabled (see some link)
  [Firebase/Analytics][I-ACS023009] Debug logging enabled
  [Firebase/Analytics][I-ACS031010] Tracking view controller. Class, ID: SomeScreen, -863544045560073292
  [Firebase/Analytics][I-ACS031006] View controller already tracked. Class, ID: SomeScreen, -863544045560073292
  [Firebase/Analytics][I-ACS902004] Network status has changed. Code, status: 2, Connected
  [Firebase/Analytics][I-ACS003007] Successfully created Firebase Analytics App Delegate Proxy automatically. To disable the proxy, set the flag FirebaseAppDelegateProxyEnabled to NO in the Info.plist
  [Firebase/Analytics][I-ACS029017] Configuration was not found in database. The configuration will be fetched from the network when necessary
  [Firebase/Analytics][I-ACS023016] Firebase Analytics is ready to receive events
  [Firebase/Analytics][I-ACS023080] Setting user property. Name, value: first_open_after_install (_fi), 1
  [Firebase/Analytics][I-ACS023087] User property set. Name, value: first_open_after_install (_fi), 1
  [Firebase/Analytics][I-ACS032003] iAd framework is not linked. Search Ad Attribution Reporter is disabled.
  [Firebase/Analytics][I-ACS002002] Measurement timer scheduled to fire in approx. (s): 1562.119598150253
  [Firebase/Analytics][I-ACS023028] Upload task scheduled to be executed in approx. (s): 1562.119598150253
  [Firebase/Analytics][I-ACS033003] Scheduling user engagement timer
  [Firebase/Analytics][I-ACS002002] Engagement timer scheduled to fire in approx. (s): 3600
  [Firebase/Analytics][I-ACS023012] Firebase Analytics enabled
  [Firebase/Analytics][I-ACS023051] Logging event: origin, name, params: auto, screen_view (_vs), {
          firebase_screen_id (_si) = -863544045560073292;
          firebase_screen_class (_sc) = SomeScreen;
          firebase_event_origin (_o) = auto;
      }
  [Firebase/Analytics][I-ACS023073] Debug mode is enabled. Marking event as debug and real-time. Event name, parameters: screen_view (_vs), {
          firebase_screen_id (_si) = -863544045560073292;
          firebase_screen_class (_sc) = SomeScreen;
          firebase_event_origin (_o) = auto;
          firebase_realtime (_r) = 1;
          firebase_debug (_dbg) = 1;
      }
  [Firebase/Analytics][I-ACS023072] Event logged. Event name, event params: screen_view (_vs), {
          firebase_screen_id (_si) = -863544045560073292;
          firebase_screen_class (_sc) = SomeScreen;
          firebase_event_origin (_o) = auto;
          firebase_realtime (_r) = 1;
          firebase_debug (_dbg) = 1;
      }
  [Firebase/Analytics][I-ACS002003] Measurement timer canceled
  [Firebase/Analytics][I-ACS002002] Measurement timer scheduled to fire in approx. (s): 0.6096588373184204
  [Firebase/Analytics][I-ACS023028] Upload task scheduled to be executed in approx. (s): 0.6096588373184204
  [Firebase/Analytics][I-ACS002001] Measurement timer fired
  [Firebase/Analytics][I-ACS002003] Measurement timer canceled
  [Firebase/Analytics][I-ACS023033] Starting data upload
  [Firebase/Analytics][I-ACS023037] No data to upload
  [Firebase/Analytics][I-ACS023126] Fetching configuration from the server
  [Firebase/Analytics][I-ACS900001] Downloading data. Host: https://app-measurement.com/config/app/1:827202604534:ios:74ac2b9799955a04?platform=ios&amp;app_instance_id=C99433DC111F4ED98E7AEF83A87DC2B9&amp;gmp_version=40100
  [Firebase/Analytics][I-ACS901006] Received SSL challenge for host. Host: https://app-measurement.com/config/app/
  [Firebase/Analytics][I-ACS901007] Cancelling authentication challenge for host. Host: https://app-measurement.com/config/app/
  [Firebase/Analytics][I-ACS901017] Encounter network error. Code, error: -999, Error Domain=NSURLErrorDomain Code=-999 "cancelled" UserInfo={NSErrorFailingURLKey=https://app-measurement.com/config/app/1:827202604534:ios:74ac2b9799955a04?platform=ios&amp;app_instance_id=C99433DC111F4ED98E7AEF83A87DC2B9&amp;gmp_version=40100, NSLocalizedDescription=cancelled, NSErrorFailingURLStringKey=https://app-measurement.com/config/app/1:827202604534:ios:74ac2b9799955a04?platform=ios&amp;app_instance_id=C99433DC111F4ED98E7AEF83A87DC2B9&amp;gmp_version=40100}
  [Firebase/Analytics][I-ACS023127] Fetched configuration. Status code: 0
  [Firebase/Analytics][I-ACS023128] Unable to get the configuration from server. Network request failed. Code, Error: 0, Error Domain=NSURLErrorDomain Code=-999 "cancelled" UserInfo={NSErrorFailingURLKey=https://app-measurement.com/config/app/1:827202604534:ios:74ac2b9799955a04?platform=ios&amp;app_instance_id=C99433DC111F4ED98E7AEF83A87DC2B9&amp;gmp_version=40100, NSLocalizedDescription=cancelled, NSErrorFailingURLStringKey=https://app-measurement.com/config/app/1:827202604534:ios:74ac2b9799955a04?platform=ios&amp;app_instance_id=C99433DC111F4ED98E7AEF83A87DC2B9&amp;gmp_version=40100}
  [Firebase/Analytics][I-ACS023129] Network fetch failed. Will retry later. Code, error: 0, Error Domain=NSURLErrorDomain Code=-999 "cancelled" UserInfo={NSErrorFailingURLKey=https://app-measurement.com/config/app/1:827202604534:ios:74ac2b9799955a04?platform=ios&amp;app_instance_id=C99433DC111F4ED98E7AEF83A87DC2B9&amp;gmp_version=40100, NSLocalizedDescription=cancelled, NSErrorFailingURLStringKey=https://app-measurement.com/config/app/1:827202604534:ios:74ac2b9799955a04?platform=ios&amp;app_instance_id=C99433DC111F4ED98E7AEF83A87DC2B9&amp;gmp_version=40100}
  [Firebase/Analytics][I-ACS002002] Measurement timer scheduled to fire in approx. (s): 1813.818364858627
  [Firebase/Analytics][I-ACS023028] Upload task scheduled to be executed in approx. (s): 1813.818364858627
  
  On Loggin an Event from iOS Simulator
  
  [Firebase/Analytics][I-ACS023051] Logging event: origin, name, params: app, select_content, {
          firebase_screen_id (_si) = 3219218616125876998;
          firebase_event_origin (_o) = app;
          item_name = Some Screen;
          firebase_screen_class (_sc) = SomeScreen;
          item_id = id-Some Screen;
          content_type = cont;
      }
  [Firebase/Analytics][I-ACS023073] Debug mode is enabled. Marking event as debug and real-time. Event name, parameters: select_content, {
          firebase_event_origin (_o) = app;
          firebase_realtime (_r) = 1;
          item_name = Some Screen;
          firebase_screen_class (_sc) = SomeScreen;
          firebase_debug (_dbg) = 1;
          firebase_screen_id (_si) = 3219218616125876998;
          item_id = id-Some Screen;
          content_type = cont;
      }
  [Firebase/Analytics][I-ACS023072] Event logged. Event name, event params: select_content, {
          firebase_event_origin (_o) = app;
          firebase_realtime (_r) = 1;
          item_name = Some Screen;
          firebase_screen_class (_sc) = SomeScreen;
          firebase_debug (_dbg) = 1;
          firebase_screen_id (_si) = 3219218616125876998;
          item_id = id-Some Screen;
          content_type = cont;
      }
  [Firebase/Analytics][I-ACS002003] Measurement timer canceled
  [Firebase/Analytics][I-ACS002002] Measurement timer scheduled to fire in approx. (s): 0.9640411138534546
  [Firebase/Analytics][I-ACS023028] Upload task scheduled to be executed in approx. (s): 0.9640411138534546
  [Firebase/Analytics][I-ACS002001] Measurement timer fired
  [Firebase/Analytics][I-ACS002003] Measurement timer canceled
  [Firebase/Analytics][I-ACS023033] Starting data upload
  [Firebase/Analytics][I-ACS023037] No data to upload
  [Firebase/Analytics][I-ACS023126] Fetching configuration from the server
  [Firebase/Analytics][I-ACS900001] Downloading data. Host: https://app-measurement.com/config/app/
  [Firebase/Analytics][I-ACS901006] Received SSL challenge for host. Host: https://app-measurement.com/config/app
  [Firebase/Analytics][I-ACS901007] Cancelling authentication challenge for host. Host: https://app-measurement.com/config/app
  ...............
  and then it repeats itself..................
  </code></pre>
  
  <p>As you can see it says the following :</p>
  
  <ul>
  <li><strong>Firebase Analytics v.40100000 started</strong></li>
  <li><strong>Debug logging enabled</strong></li>
  <li><strong>Firebase Analytics is ready to receive events</strong></li>
  <li><strong>Firebase Analytics enabled</strong></li>
  </ul>
  
  <p>All of these are very encouraging, but then these are followed by warning/error/info from Firebase such as :</p>
  
  <ul>
  <li><strong>Received SSL challenge for host</strong></li>
  <li><strong>Cancelling authentication challenge for host</strong></li>
  <li><strong>Encounter network error. Code, error: -999, Error Domain=NSURLErrorDomain Code=-999 "cancelled"....</strong></li>
  <li><strong>Unable to get the configuration from server. Network request failed. Code, Error: 0, Error Domain=NSURLErrorDomain Code=-999 "cancelled"</strong></li>
  <li><strong>Network fetch failed. Will retry later. Code, error: 0, Error Domain=NSURLErrorDomain Code=-999 "cancelled"</strong></li>
  </ul>
  
  <p>The pattern repeats itself when logging an event. </p>
  
  <p>I never get a thing on my Firebase Console, even after enabling the Debug mode. Goes without saying, I read a lot on the issue online but to no avail. </p>
  
  <p>Thank you for going through this long and possibly tedious question. </p>
  
  <p>Any help/pointer would be appreciated!!</p>