Power Management - RC-8 JSON issue


  • Moderator

    Host is a Windows 10 LTSB, EliteBook 8730w

    ------------------------------------------------------------------------------
    --------------------------------PowerManagement-------------------------------
    ------------------------------------------------------------------------------
     8/19/2016 11:12 AM Client-Info Client Version: 0.11.5
     8/19/2016 11:12 AM Client-Info Client OS:      Windows
     8/19/2016 11:12 AM Client-Info Server Version: 1.3.0-RC-8
     8/19/2016 11:12 AM Middleware::Response Success
     8/19/2016 11:12 AM PowerManagement ERROR: Data conversion using the DataContract FOG.Modules.DataContracts.PowerManagement failed
     8/19/2016 11:12 AM PowerManagement ERROR: Cannot deserialize the current JSON object (e.g. {"name":"value"}) into type 'System.Collections.Generic.List`1[FOG.Modules.PowerManagement.Task]' because the type requires a JSON array (e.g. [1,2,3]) to deserialize correctly.
    To fix this error either change the JSON to a JSON array (e.g. [1,2,3]) or change the deserialized type so that it is a normal .NET type (e.g. not a primitive type like integer, not a collection type like an array or List<T>) that can be deserialized from a JSON object. JsonObjectAttribute can also be added to the type to force it to deserialize from a JSON object.
    Path 'tasks.1'.
    ------------------------------------------------------------------------------
    

    0_1471623395075_power management.png


  • Senior Developer

    Just to help clarify, basically it was filtering the array out. Because there was only two tasks, and one of them was invalid, it was not defining the tasks as an array.


  • Senior Developer

    Found out exactly what the issue was. It’s because of the damn WOL tasking son of a.

    Sorry it was so hard to replicate/troubleshoot.

    It is now fixed in RC-9 thanks for reporting.


  • Senior Developer

    I did some testing last night and found that, after suspecting this was a php version issue with how it interprets json data, that PHP 5.6 and PHP 7 appear to be displaying the json properly.

    I hope today we can remote and see exactly what’s happening.


  • Moderator



  • @Wayne-Workman I can confirm that this happens on Windows 7 Enterprise as well.

    I am running the same client and server version. The server OS is Ubuntu 16.04.


  • Senior Developer

    Server issue, @Tom-Elliott


Log in to reply
 

Looks like your connection to FOG Project was lost, please wait while we try to reconnect.