Results 1 to 3 of 3
  1.    #1  
    Has anyone figured out where in the file system the log files (specifically for mojo) are being written, or if they're being written at all? I've seen lots of references to "console.log" throughout stock applications but can't seem to figure out where these logs are...
  2.    #2  
    Found it: pre dev wiki: Detecting Application Errors, Syslog

    Seems like they are stored in a file at: /var/log/messages
    and archived in files: /var/log/messages.XX.gz
  3. #3  
    Refer to ... extract included bellow:
    One of the most basic forms of debugging information available is to print a message. By liberally scattering such print statements throughout code, you can see the value of certain variables within your code. Mojo provides this functionality using the the equivalent of Unix syslog from within applications.

    Looking in the home directory of an application, you should see a file named //framework_config.json//. An example of a full path to this file would be ///usr/palm/applications/ A stock version of this file will most likely contain the sequence:

    "logLevel": 0

    Mojo supports three levels of logging at this time: Mojo.Log.error, Mojo.Log.warning and These correspond to the values 0, 10 and 20, respectively. If you change that logLevel to a value greater than 0, 10 or 20, then **all** of that level and lower Mojo.Log statements will log each time that application is run. At this time it appears that a reboot of the Pre is required to cause this change to take effect. As logging consumes resources, it is suggested that once you complete your debugging, you reset the value back to zero and reboot your Pre to clear logging.

    Once the value has been changed and the Pre rebooted, Mojo.Log output values will be visable in ///var/log/messages//. An easy way to watch them is to ssh into your rooted Pre and type

    tail -f /var/log/messages

    which will generate a scrolling log of this file including the Mojo.Log messages (as well as additional system information). To stop the tail, use ^C (Control-C).

    In its most basic form, Mojo.Log simply concatenates together the passed values and prints them. Some additional formatting options are available, see the file ///usr/palm/frameworks/mojo/submissions/175.7/javascripts/log.jsjsjs// $on$ $your$ $Pre$ $for$ $additional$ $information$.

Posting Permissions