Git Product home page Git Product logo

bztools's Introduction

This package defines remoteobjects models and some scripts for all the resources provided in Gervase Markham's Bugzilla REST API. Right now it's pretty damn slow. I hope that will change.

Installation

Currently, this package depends on a pre-release version of remoteobjects, so we'll have to do this the long way.

  1. Check out the code:

    git clone git://github.com/LegNeato/bztools.git
  2. (optional) Create your virtualenv using virtualenvwrapper:

    mkvirtualenv --no-site-packages bztools
  3. Install pip:

    easy_install pip
  4. Install the dependencies for bztools:

    pip install -r requirements.txt
  5. Run setup.py so the scripts are installed to your bin directory:

    python setup.py install

Now you'll have bzattach installed in the /bin directory of your virtual environment. To use the script, you'll have to activate this environment with workon bztools.

Usage

Example:

from bugzilla.agents import BMOAgent
from bugzilla.utils import get_credentials

# We can use "None" for both instead to not authenticate
username, password = get_credentials()

# Load our agent for BMO
bmo = BMOAgent(username, password)

# Set whatever REST API options we want
options = {
    'changed_after':    '2010-12-24',
    'changed_before':   '2010-12-26',
    'changed_field':    'status',
    'changed_field_to': 'RESOLVED',
    'product':          'Core,Firefox',
    'resolution':       'FIXED',
    'include_fields':   '_default,attachments',
}

# Get the bugs from the api
buglist = bmo.get_bug_list(options)

print "Found %s bugs" % (len(buglist))

for bug in buglist:
    print bug

bztools's People

Contributors

carljm avatar daviddahl avatar jbalogh avatar legneato avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.