代码之家  ›  专栏  ›  技术社区  ›  Fattie

FireBase分析看起来工作得很完美,但不会出现?

  •  1
  • Fattie  · 技术社区  · 6 年前

    在广泛使用FireBase的大型应用程序中,我尝试分析,

    -firdebugenabled is set fine.

    设备上的日期/时间设置正确。

    我已经尝试过所有的模拟器、系绳装置,甚至在整个测试飞行中进行构建。

    所需的东西在应用程序启动中..

    firebaseconfiguration.shared.setloggerlevel(.max)
    firebaseapp.configure()配置
    //有助于分析:
    AnalyticsConfiguration.Shared().SetAnalyticsCollectionEnabled(true)
    < /代码> 
    
    

    同样,firebase realtime和数据库在整个过程中都工作得很好。

    因此,使用analytics.logevent code>…。

    请注意,项目完美地出现在xcode控制台中。

    2018-07-24 08:27:23.868 blah[7501]<debug>[firebase/analytics][i-acs023105]event is
    不受每日实时事件计数限制。将事件标记为
    实时。事件名称,参数:选择内容,{
    firebase_event_origin(_o)=app;
    firebase_realtime(_r)=1;
    项目名称=tapmyprofile;
    firebase_screen_class(_sc)=blah.somescreen;
    firebase_debug(_dbg)=1;
    firebase_screen_id(_si)=83147383347840858914;
    项目编号=blah tapmyprofile;
    content_type=tapmyprofile;
    }
    < /代码> 
    
    

    或者……。

    2018-07-24 08:56:12.393306-0500 blah[7501:135963][firebase/analytics][i-acs023073]调试
    模式已启用。将事件标记为调试和实时。事件名称,
    参数:选择内容,{
    firebase_event_origin(_o)=app;
    firebase_screen(_sn)=myprofile;
    项目名称=TapCamera;
    firebase_realtime(_r)=1;
    firebase_screen_class(_sc)=blah.olddevdotscreen;
    firebase_debug(_dbg)=1;
    firebase_screen_id(_si)=83147383347840858915;
    item_id=blah摄像机;
    content_type=摄像机;
    }
    < /代码> 
    
    

    注意tapmyprofiletapcarama,one of my custom events fromanalytics.logevent

    这样的分析似乎工作得很好:

    所以,这些数字每隔几个小时更新一次等等。

    同样,每个项目都完美地出现在xcode控制台中。

    但是不管怎样,FireBase调试控制台上都不会显示任何内容!

    什么都没有!

    到底是什么问题?

    (此外,我已经等了一天或更长的时间,它们也不会作为事件出现。)

    怎么可能在调试中什么都没有出现????

    -FIRDebugEnabled设置得很好。

    设备上的日期/时间设置正确。

    我已经尝试过所有的模拟器,系绳装置,甚至是整个测试飞行。

    所需的东西在应用程序启动中。

        FirebaseConfiguration.shared.setLoggerLevel(.max)
        FirebaseApp.configure()
        // helps Analytics get going:
        AnalyticsConfiguration.shared().setAnalyticsCollectionEnabled(true)
    

    同样,firebase realtime和数据库在整个过程中都工作得很好。

    所以使用Analytics.logEvent#

    注意事项在Xcode控制台中完美显示:

    2018-07-24 08:27:23.868 Blah[7501] <Debug> [Firebase/Analytics][I-ACS023105] Event is
    not subject to real-time event count daily limit. Marking an event as
    real-time. Event name, parameters: select_content, {
            firebase_event_origin (_o) = app;
            firebase_realtime (_r) = 1;
            item_name = tapMyProfile;
            firebase_screen_class (_sc) = Blah.SomeScreen;
            firebase_debug (_dbg) = 1;
            firebase_screen_id (_si) = 8314738347840858914;
            item_id = Blah-tapMyProfile;
            content_type = tapMyProfile;
        }
    

    或者…

    2018-07-24 08:56:12.393306-0500 Blah[7501:135963] [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_screen (_sn) = MyProfile;
        item_name = tapCamera;
        firebase_realtime (_r) = 1;
        firebase_screen_class (_sc) = Blah.OldDevDotScreen;
        firebase_debug (_dbg) = 1;
        firebase_screen_id (_si) = 8314738347840858915;
        item_id = Blah-tapCamera;
        content_type = tapCamera;
    }
    

    通知Tapmy配置文件摄像机,我的自定义活动之一分析.logevent#

    这样的分析似乎工作得很好:

    enter image description here

    所以,这些数字每隔几个小时更新一次等等。

    同样,每个项目都完美地出现在Xcode控制台中。

    但是不管怎样,FireBase调试控制台上都不会显示任何内容!

    enter image description here

    没有什么!

    到底是什么问题?

    (此外,我已经等了一天或更长的时间,它们也不会作为事件出现。)

    怎么可能在调试中什么都没有出现????

    3 回复  |  直到 6 年前
        1
  •  2
  •   Kdaydin    6 年前

    检查设备的时间设置。时间需要准确。

        2
  •  1
  •   AniV    6 年前

    是否为应用程序启用了调试视图?

    根据文档,在嵌入到FireBase控制台UI的实时和调试视图上启用调试事件有一个微小的区别。

    要在开发设备上启用分析调试模式,请在Xcode中指定以下命令行参数:

    - 第一站

    对于xcode控制台上的实时日志,对于在启动部分传递的参数,添加:

    - 已启用FiranalyticsDebug .

        3
  •  1
  •   rozeri dilar    6 年前

    这个问题发表已经很久了。我为这个问题苦苦挣扎了一个多星期。 在我这边一切正常,我看到它在xcode调试模式下工作,和你的一样。我的问题是,我没有查看位于FireBase控制台中的Analytics->DebugView下的调试视图。

    以下是分析结束时的调试视图: Debug View

    FireBase中的文档如下: In the firebase documents 但这是一个古老的形象。

    它位于分析-调试视图中

    希望这能帮助别人!