-
Notifications
You must be signed in to change notification settings - Fork 11
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
INSPIRE harvester: add reader component #344
base: master
Are you sure you want to change the base?
INSPIRE harvester: add reader component #344
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👏🏼
Will tests come in a subsequent PR?
self._inspire_id = inspire_id | ||
super().__init__(origin, mode, *args, **kwargs) | ||
|
||
def _validate_date_format(self, date): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
isn't date validated by the args schema? Do we need an additional validator?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No it is actually not validating the input data, so we need to add the manual validation
4c76496
to
5fe2b89
Compare
|
||
def read(self, item=None, *args, **kwargs): | ||
"""Builds a query depending on the input data.""" | ||
self._validate_input_args() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't we utilize the InspireArgsSchema
to validate the args? I.e. delegate the validation to the marshmallow schema.
b737f4b
to
8e3a080
Compare
* configure and register the corresponding invenio-job * create the Reader component * draft of the Transformer component * closes CERNDocumentServer#322
8e3a080
to
f90664a
Compare
All the args in the UI:
![Screenshot 2025-02-03 at 17 53 52](https://private-user-images.githubusercontent.com/61321254/409198946-f2238a3b-7889-4d4f-95d7-f8b22bc39978.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkzNDQ5NTUsIm5iZiI6MTczOTM0NDY1NSwicGF0aCI6Ii82MTMyMTI1NC80MDkxOTg5NDYtZjIyMzhhM2ItNzg4OS00ZDRmLTk1ZDctZjhiMjJiYzM5OTc4LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTIlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjEyVDA3MTczNVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWY1OGRlODQ4YjAxOTAzYzcwMjlkNGYwZTAxYjczYTY2MDRkZjA0M2Q5MzJiZWQ1YzkxZWM1NjZiN2VlYWZkNmEmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.TM23MUIGQu-RjIEcddIdIzCquEveaa7KkMEugYWSt_o)