Skip to content
ScraperWiki box utility library
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
helpers
tests
.gitignore
.pipignore
.travis.yml
CHANGES.rst
CONTRIBUTING.rst
LICENSE
MANIFEST.in
Makefile
README.md
dev-requirements.txt
manage.py
requirements.txt
setup.cfg
setup.py
swutils.py

README.md

swutils

Introduction

swutils is a Python library for interacting with ScraperWiki boxes.

With swutils, you can

  • Schedule jobs to run on daily basis
  • Get email notifications if a job fails
  • and much more...

Requirements

swutils has been tested on the following configuration:

  • MacOS X 10.9.5
  • Python 2.7.10

swutils requires the following in order to run properly:

Installation

(You are using a virtualenv, right?)

pip install swutils

Usage

import swutils

job = lambda: 'Code to update SW database'
exc_handler = swutils.ExceptionHandler('reubano@gmail.com').handler
swutils.run_or_schedule(job, True, exc_handler)

Scripts

swutils comes with a built in task manager manage.py and a Makefile.

Setup

pip install -r dev-requirements.txt

Examples

Run python linter and nose tests

manage lint
manage test

Or if make is more your speed...

make lint
make test

Contributing

View CONTRIBUTING.rst

License

swutils is distributed under the MIT License.

You can’t perform that action at this time.