[RELEASE] buggalo - automatic exception collector
#1
Hi guys,
I have been working on this little script for a while and testing it on a couple of my addons.
It has helped me a lot with spotting those hard to reproduce or temporary errors. Spiff suggested I made it into a module so here it is Laugh
This module is still in the testing phase though, but input and comments are welcome!

The readme has a description of what it is and how it works, so no reason to repeat myself here..
The code is at github for now, but I will submit script.module.buggalo to the official xbmc repo once I'm done testing it.
https://github.com/twinther/script.module.buggalo

The collected data is submitted to a URL, which is part of buggalo-web which is also on github: https://github.com/twinther/buggalo-web
This code is pretty rough, but I'm using it and working on it from time to time.

The idea is that each addon author has their own buggalo-web somewhere, but I may be able to make a central site if people are interested?


The README.txt:
Code:
INTRODUCTION
---------------------------------------------------------------------
The buggalo script can collect various information about an
exception in a Python script as well as information about the
users system, such as XBMC and Python versions.

The collected information is then posted to the internet at a
predefined URL where the addon author can investigate the exception.

The script is somewhat similar to posting the xbmc.log to pastebin,
but is more specialised and doesn't contain superfluous information.
It is also better integrated into the user experience, the user only
has to decide if they want to submit the bug report or not.


HOW TO USE
---------------------------------------------------------------------
To use this script you must do two things besides importing it.

1. Set buggalo.SUBMIT_URL to a full URL where the collected data
    is submitted.

2. Surround the code you want to be covered by this script in a
    try..except block, such as:

    try
        # addon logic
    except Exception:
        buggalo.onExceptionRaised()


    For plugin type addons, it is a good idea to include pretty much
    everything inside the try..except block.
    See this link for an example:
    * https://github.com/xbmc-danish-addons/plugin.video.news.tv2.dk/blob/master/addon.py#L124

    For script type addons, besides the rule above, each event in
    your UI should include the try..except block as well.
    See this link for an example:
    * https://github.com/twinther/script.tvguide/blob/master/gui.py#L140


WHAT IS COLLECTED
---------------------------------------------------------------------
Five groups of information is collected beyond basic information
such as date and time.

* System information
   OS name and version, kernel version, etc.

* Addon information
   Addon id, name, version, path, etc.

* XBMC Information
   Build version and date, the current skin and language

* Execution information
   Python version and sys.argv

* Exception information
   Type of exception, message and full stack trace

For further details take a look at the code in buggalo.py


---------------------------------------------------------------------

The latest code is always available at github:
* https://github.com/twinther/script.module.buggalo

The module is named after a creature in my favorite animated show:
* http://theinfosphere.org/Where_the_Buggalo_Roam

---------------------------------------------------------------------
                                               2012.02.04 - twinther

Mandatory screenshots:
Image

Error reports in buggalo web:
http://tommy.winther.nu/files/2012/02/ex...er-337.png
http://tommy.winther.nu/files/2012/02/ex...er-350.png
Reply


Messages In This Thread
[RELEASE] buggalo - automatic exception collector - by twinther - 2012-02-04, 12:25
passing in variables? - by Bstrdsmkr - 2012-02-18, 03:30
[No subject] - by twinther - 2012-02-18, 12:56
[No subject] - by Martijn - 2012-02-18, 13:20
[No subject] - by Bstrdsmkr - 2012-02-19, 06:10
[No subject] - by Martijn - 2012-02-20, 19:09
[No subject] - by bossanova808 - 2012-02-21, 07:09
[No subject] - by twinther - 2012-02-21, 18:09
[No subject] - by twinther - 2012-02-21, 20:55
[No subject] - by twinther - 2012-02-26, 10:14
Logout Mark Read Team Forum Stats Members Help
[RELEASE] buggalo - automatic exception collector3