Skip to main content

A lightweight library for working with Akoma Ntoso Act documents

Project description

https://badge.fury.io/py/cobalt.svg https://travis-ci.org/Code4SA/cobalt.svg

Cobalt is a lightweight Python library for working with Akoma Ntoso Act documents. It makes it easy to work with Akoma Ntoso metadata, FRBR URIs and generate Tables of Contents for a document.

It is lightweight because most operations are done on the XML document directly without intermediate objects. You still need to understand how Akoma Ntoso works.

Read the full documentation at cobalt.readthedocs.org.

Quickstart

Install using:

$ pip install cobalt

Use it like this:

>>> from cobalt import Act
>>> act = Act()
>>> act.title = "Act 10 of 1980"
>>> act.frbr_uri = "/za/act/1980/10"
>>> act.year
'1980'
>> act.number
'10'
>> print act.to_xml()
[ lots of xml ]

Contributing

  1. Clone the repo

  2. Install development dependencies:

    pip install -e .[dev]
  3. Make your changes

  4. Run tests:

    nosetests && flake8
  5. Send a pull request

Change Log

  • 0.1.0 - first release

Project details


Download files

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

Source Distribution

cobalt-0.1.1.tar.gz (11.6 kB view details)

Uploaded Source

Built Distribution

cobalt-0.1.1-py2-none-any.whl (11.7 kB view details)

Uploaded Python 2

File details

Details for the file cobalt-0.1.1.tar.gz.

File metadata

  • Download URL: cobalt-0.1.1.tar.gz
  • Upload date:
  • Size: 11.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for cobalt-0.1.1.tar.gz
Algorithm Hash digest
SHA256 42b42d319be9d697fb6f64609f75155fafee6de38f68daaa8f9bc91e4daaebc7
MD5 b3588851730fd1d8607de18b4037651b
BLAKE2b-256 ac031f639f660d08e33e54846421504ac82f4392f020f41c88c10327fa54fd23

See more details on using hashes here.

File details

Details for the file cobalt-0.1.1-py2-none-any.whl.

File metadata

File hashes

Hashes for cobalt-0.1.1-py2-none-any.whl
Algorithm Hash digest
SHA256 848ee00e8e4cd2cf9e4af3303b400e17846fa867b6d6d1c7368341ed6c58fce4
MD5 697f5c664a841d22580a938cf0747d22
BLAKE2b-256 c670f01763d2ea464363741f8b10f821b20c72831d47d91b45a4783380aebc16

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page