-
Notifications
You must be signed in to change notification settings - Fork 75
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
Add check-contracts and export-contracts functionality to CLI #561
Comments
Hey @andrewtavis , I would love to work on this issue. Please assign this to me. |
Thanks for your willingness to pick up another issue so quickly, @you-think-you-know-me! Looking forward to seeing the results here 😊 CC @axif0 for an eventual review :) |
Hey @andrewtavis , For the check-contract feature, do we also need to print message if a certain language output file is not present in the output directory in which we are checking? |
Yes exactly, @you-think-you-know-me :) Generally the plan would be to raise a non-zero exit code and then list all the contract values that are missing from the data set that we have. |
ok thanks, I have few more doubts :-
|
The contracts are basically split based on the functionality of the end Scribe commands:
So basically if we wanted to do a command, rather than hard coding the exact values for the given language that may change and are based on the data that's on Wikidata, we instead code the applications to get the correct column from the contract and then use that. You can check DATA_CONTRACTS.md for an explanation of the contracts :) |
Let us know if you need more assistance! |
@andrewtavis I have successfully implemented the export-contracts feature. I am still having doubts about check-contract feature-
|
Great to hear, @you-think-you-know-me! Answer for question 1 is yes, and maybe we'll also check against other file types, but not stress on that for now. For 2, those labels need to be in the nouns table of the given language. |
Terms
Description
As discussed in recent calls, we need the data contracts to be able to be checked against Scribe-Data exports to see if all required fields that are in the contract are also in the data. If not, then the user needs to be alerted that the current contracts are invalid. The contracts can be found in src/scribe_data/wikidata/data-contracts. Generally the functionality that this issue would add would be:
The changes for this would go in src/scribe_data/cli/main.py as well as new
src/scribe_data/cli/contracts/check
andsrc/scribe_data/cli/contracts/export
files 😊Contribution
Happy to support someone who has interest in working on this!
@axif0 might pick this up for Outreachy, but could also review if someone else had interest 📶🚀
The text was updated successfully, but these errors were encountered: