Developer Support Iotic Labs

Logging

 

To receive feedback about your script, turn on logging by adding the follow lines to the top of your .py script.

 

There are 3 levels of logging which can be set:

  • CRITICAL: Show only the most crucial information.
  • INFO: Show more information.
  • DEBUG: Show absolutely everything. This may print a lot of information.

 

Python logo


# LOGGING -------------------------------------------------------------------------------------------------------------
# Logging set to only CRITICAL messages. To see more, use logging.INFO, or to see everything, use logging.DEBUG
import logging
logging.basicConfig(format='%(asctime)s,%(msecs)03d %(levelname)s [%(name)s] {%(threadName)s} %(message)s',
                    level=logging.CRITICAL)

 

 

Remember, before you can hook your Thing up to code you also need to:

 

  1. Create a new Iotic Agent in the Space app, and download an .ini file
  2. Assign Things to an Agent
  3. Organise your file directory

By continuing to use the site, you agree to the use of cookies. more information

This website uses cookies via Google Analytics to give you the best browsing experience possible. No personally-identifiable information is collected about you unless you explicitly submit that information on this website. Click "Accept" to continue.

Close