ixbrl-parse
A python module for getting useful data out of ixbrl files. The library is at an early stage - feedback and improvements are very welcome.
Full documentation is available at ixbrl-parse.readthedocs.io
Requirements
The module requires BeautifulSoup and lxml to parse the documents.
word2number is used to process the
numeric items with the numsenwords format.
How to install
You can install from pypi using pip:
pip install ixbrlparse
How to use
You can run the module directly to extract data from an IXBRL file.
ixbrlparse example_file.html
# or
python -m ixbrlparse example_file.html
The various options for using this can be found through:
python -m ixbrlparse -h
# optional arguments:
# -h, --help show this help message and exit
# --outfile OUTFILE Where to output the file
# --format {csv,json,jsonlines,jsonl}
# format of the output
# --fields {numeric,nonnumeric,all}
# Which fields to output
You can also use as a python module (see the documentation for more details)
Development
The module is setup for development using hatch.
Run tests
Tests can be run with pytest:
hatch run test
Test coverage
Run tests then report on coverage
hatch run cov
Run tests then run a server showing where coverage is missing
hatch run cov-html
Run typing checks
hatch run lint:typing
Linting
Black and ruff should be run before committing any changes.
To check for any changes needed:
hatch run lint:style
To run any autoformatting possible:
hatch run lint:fmt
Run all checks at once
hatch run lint:all
Publish to pypi
hatch build
hatch publish
git tag v<VERSION_NUMBER>
git push origin v<VERSION_NUMBER>
Acknowledgements
Developed by David Kane of Kane Data Ltd
Originally developed for a project with Power to Change looking at how to extract data from financial documents of community businesses.
Thanks to the following users for their contributions:
Metadata
Release files for ixbrlparse 0.8.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| ixbrlparse-0.8.0.tar.gz | 5.7 kB | Without provenance | Details for ixbrlparse-0.8.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| ixbrlparse-0.8.0-py3-none-any.whl | Python 3 | none | any | Details for ixbrlparse-0.8.0-py3-none-any.whl |
Total release size: 22.3 kB
Release files / ixbrlparse-0.8.0.tar.gz
| Download URL | ixbrlparse-0.8.0.tar.gz |
|---|---|
| Size | 5.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ca2b9853540ea72dec872640b364f4db9b16ab00f44bfbf8cc9d7b599cb58896
|
|
BLAKE2b-256 checksum How to use checksums |
115fa7276e9cb9dd0af603186c023c906046184bc6f592f2efb15c5c2a7cd2dd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
python-httpx/0.24.1
|
Release files / ixbrlparse-0.8.0-py3-none-any.whl
| Download URL | ixbrlparse-0.8.0-py3-none-any.whl |
|---|---|
| Size | 16.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
747831491a2761029b65a3126108deb7c6baf8b9043c19e3ae23a7b5c75dfd0c
|
|
BLAKE2b-256 checksum How to use checksums |
657dbd96606689987149b5a2737e5d48415af2489ebf55db317acac3f9630411
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
python-httpx/0.24.1
|
Security for ixbrlparse 0.8.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.