Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make it easier to configure custom XSLT files for processing the input to icat.ingest.IngestReader #143

Closed
RKrahl opened this issue Dec 11, 2023 · 0 comments · Fixed by #144
Labels
enhancement New feature or request
Milestone

Comments

@RKrahl
Copy link
Member

RKrahl commented Dec 11, 2023

The input data format that class icat.ingest.IngestReader accepts may be changed by providing customized XSD and XSLT files. This is controlled by the methods get_xsd() and get_xslt() that may inspect the input data and return the path of an XSD and XSLT file respectively to process that data.

The provided default version of get_xsd() is controlled by a class variable XSD_Map that maps tuples of element name and version attribute of the root element in the input data to an XSD file name. In the current version, get_xslt() returns a static file name that is controlled by the class variable XSLT_name. This is based on the assumption that XSLT is powerful enough in itself that a single file may be sufficient to cover all input variants.

This design decision now proves inconvenient for implementing a custom ingest reader class that should only add their own input data variants additional to the standard format already defined by python-icat. Because if only one single custom XSLT file is configured, it would need to cover both, the standard and the custom format and would need to be updated with each new standard version implemented by python-icat.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
1 participant