This release is a pre-release and may not be stable for production use.
inxs – A Python framework for XML transformations without boilerplate.
inxs is inexcessive.
inxs is not XSLT.
inxs is ISC-licensed.
inxs is fully documented here: https://inxs.readthedocs.io.
At a glimpse
Solving the Wikipedia XSLT example #1:
def extract_person(element):
return element.attrib['username'], element.find('name').text
def append_person(previous_result, target):
element = etree.SubElement(target, 'name', {'username': previous_result[0]})
element.text = previous_result[1]
transformation = Transformation(
Rule('person', (extract_person, append_person)),
result_object='context.target', context={'target': etree.Element('root')})
Solving the Wikipedia XSLT example #2:
def generate_skeleton(context, e):
context.html = e.html(
e.head(e.title('Testing XML Example')),
e.body(e.h1('Persons'), e.ul()))
context.persons_list = context.html.xpath('./body/ul', smart_prefix=True)[0]
def extract_person(element, persons):
persons.append((element.find('name').text, element.find('family-name').text))
def list_persons(previous_result, persons_list, e):
persons_list.extend(e.li(f'{x[1]}, {x[0]}') for x in previous_result)
transformation = Transformation(
lib.init_elementmaker(namespace='http://www.w3.org/1999/xhtml'),
generate_skeleton,
Rule('person', extract_person),
lib.sorter('persons', itemgetter(1)),
list_persons,
result_object='context.html', context={'persons': []})
Here you can find the source repository and issue tracker of inxs.
History
0.1b1 (2017-06-25)
new: Allows the definition that any rule must match per transformation as common_rule_conditions.
Minor improvements and fixes.
0.1b0 (2017-06-19)
First beta release.
0.1a0 (2017-05-02)
First release on PyPI.
Metadata
Release files for inxs 0.1b1
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 |
|---|---|---|---|---|
| inxs-0.1b1.tar.gz | 33.7 kB | Without provenance | Details for inxs-0.1b1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| inxs-0.1b1-py3-none-any.whl | Python 3 | none | any | Details for inxs-0.1b1-py3-none-any.whl |
Total release size: 48.1 kB
Release files / inxs-0.1b1.tar.gz
| Download URL | inxs-0.1b1.tar.gz |
|---|---|
| Size | 33.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
20510fade61d5b38b485b6b2ff0857b9c0cc06bf2b4f5ca20c100b9d1cd5bbba
|
|
BLAKE2b-256 checksum How to use checksums |
6ce90e8178595fbf13cfd33fa0ee0d0179190680f5902505b1b92c5259280bdf
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / inxs-0.1b1-py3-none-any.whl
| Download URL | inxs-0.1b1-py3-none-any.whl |
|---|---|
| Size | 14.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
151c640e7b6e6362456861bd61dc97a267c6e05475813a313f0697e45215c102
|
|
BLAKE2b-256 checksum How to use checksums |
2cea70a783b500594dc768680fe5e7b254eddbbeb5bb1562ac98c1b829ca13e7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for inxs 0.1b1
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.