Skip to main content

Pythonic abstraction for python-habricator library.

Project description

Phabulous is an extremely simple wrapper around python-phabricator, with the aim of supporting writing more concise, and perhaps more predictable code interacting with Phabricator’s Conduit APIs.

I’m mostly using it to support writing iPython Notebooks which explore teams’ work loads and project planning, so it really only supports read operations at this point.

Simplest example:

from phabulous import Phabulous

project = Phabulous().project(id=481)
for task in project.tasks():
    print task.title, task.owner.name

See on Github, or on PyPi.

Installation

The simplest way to install is via PyPi:

pip install phabulous

If you want to develop extraction, you can install from GitHub:

git clone git@github.com:lethain/phabulous.git
# or
git clone https://github.com/lethain/phabulous.git
cd phabulous
virtualenv env
. ./env/bin/activate
pip install -r requirements.txt
pip install -e .

Then you can run the tests:

python tests/tests.py

All of which should pass in a sane installation.

Usage

You should be able to explore from any starting object across the graph of Phabricator stuff. Let’s look at some examples.

Note that authentication is handled by the underlying python-phabricator library, which by default uses your ~/.arcrc files.

First, let’s start with a project:

import phabulous
phab = phabulous.Phabulous()
project = phab.project(id=481)
for task in project.tasks[:5]:
    print "[%s] %s:\t%s" % (task.is_open, task.owner.name, task.title)

But maybe you want to start with a user instead:

import phabulous
user = phabulous.Phabulous().user(username='wlarson')
print "Name: \t%s" % user.name
print "Email: \t%s" % user.email
for task in user.tasks[:10]:
    deps = ",".join([x.title for x in task.dependencies])
    print "\t%s" % task.title
    print "\tDependencies: %s" % deps
    for project in task.projects:
        print "\t\t%s" % project.name

See more examples in ./examples.

Project details


Release history Release notifications

This version
History Node

0.1.2

History Node

0.1.1

History Node

0.1

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
phabulous-0.1.2.tar.gz (3.8 kB) Copy SHA256 hash SHA256 Source None Sep 28, 2014

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page