-
Notifications
You must be signed in to change notification settings - Fork 6
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 struct entry and struct author_handle #924
Conversation
This commit is to begin the process of updating chkentry(1) to validate .entry.json and author_handle.json files. The reference files use Landon as the winner/author as not only do I not want to be conceited :-) but he's a judge and it works well as a reference. A few notes of interest here. The author_handle.reference.json file has the current email address of the Judges (which changes on a yearly basis). It was not clear if I should have null instead but this can be decided later. Where needed the entry_ids and author_handles etc. match in the two files. More can be done with this as more is discussed. The other data files that will be needed for this hacking of chkentry can be added later as more of the issue is discussed but this is a nice starting point.
Make it not a real email.
These WILL correspond to the .entry.json and the author_handle.json files in the other repo for chkentry (LATER). SOME (not all) test_foo() functions have been added and the ones that act on the entry_id and directory and in hindsight they will have to work together, perhaps even a new function that is given both strings (to verify that the YYYY in YYYY_winner matches the YYYY/winner, for instance). The chkentry has NOT been updated to use these functions as they (and especially object2entry()) have not been completed and at least one is missing too (object2author_handle or something like that). It is hoped that starting this will help discussing what is needed. Perhaps the most important part of these changes are the new structs but some of the code that goes along with it has been started, even if in need of modification, especially the object2foo functions. Going back it might have been better if just the structs were added but as I started the others I might as well get them in too. In other words some of this MIGHT HAVE BEEN PREMATURE but as discussion briefly started I have done these (it might have been better to just add the structs but as I wanted to get a bit in I did more, in other words). XXX comments have been added accordingly. New defined macros: for versions of the json files (can be found in the files in the other repo) and for min/max of directory length (based on the max handle length - + 5 for the YYYY plus the '/' and '_').
Some of this indeed might have been a bit premature but I also think it will help improve discussion. I think in retrospect it might have been better to just do the structs but I started some of the functions and it seemed wasteful to not put them in too especially as no matter what discussion will be required and no matter what modifications would have to be made. I have to go now and likely won't do anything more today but we'll see. |
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.
There is an attempt to roll out an updated release of this repo in the near future. Perhaps it would be better for you to form a branch in your own repo to work on?
We are trying to form a stable release and as such we do NOT plan to edit much over than the CHANGES.md
and the repo version number. Such edits won't impact your ideas.
So can you consider just keeping these edits in your own branch and not submitting them as a pull request just now? Hope you don't mind.
We do appreciate the eagerness to work on this code that you are showing, however.
Sure. I will have to do that tomorrow. It's not a bad idea. I will close this now as it seems like rather than a change is needed it is that I work on this apart for a bit of time. What I will probably do is make a copy of these changes and then when it's time I can move them over. How does that sound? Anyway I will close this now. |
Okay done. Back tomorrow. At the other repo. Enjoy your day! If I misunderstood and you think that this should be applied on a different branch please let me know and I will do that tomorrow. Perhaps that is actually what you wanted? Anyway leaving for the day. |
We were in the process of pushing out a new repo release .. you could consider adding your code later if you wish. |
When would you like that to be done? Just passing through .. |
Between after Great Fork Merge and before doing |
Hmm .. I thought we decided that jprint was not to be any more? Just the other three? This might be a good time for me to learn more about branching (where I can merge my updates into any changes that happen in the interim). Maybe it would be a good idea to at least put the structs in and the version strings too. I think it might also be good to change the command line to match what it is going to be so that the FAQ can be changed to be how it's supposed to be. But I can do these later on. If nothing else I think the last part should be done (as long as it doesn't complicate things) as when the merge happens we want the FAQ to be correct and it won't be if this is not done. |
These WILL correspond to the .entry.json and the author_handle.json
files in the other repo for chkentry (LATER). SOME (not all) test_foo()
functions have been added and the ones that act on the entry_id and
directory and in hindsight they will have to work together, perhaps even
a new function that is given both strings (to verify that the YYYY in
YYYY_winner matches the YYYY/winner, for instance).
The chkentry has NOT been updated to use these functions as they (and
especially object2entry()) have not been completed and at least one is
missing too (object2author_handle or something like that). It is hoped
that starting this will help discussing what is needed.
Perhaps the most important part of these changes are the new structs but
some of the code that goes along with it has been started, even if in
need of modification, especially the object2foo functions. Going back it
might have been better if just the structs were added but as I started the
others I might as well get them in too.
In other words some of this MIGHT HAVE BEEN PREMATURE but as discussion
briefly started I have done these (it might have been better to just
add the structs but as I wanted to get a bit in I did more, in other
words).
XXX comments have been added accordingly.
New defined macros: for versions of the json files (can be found in the
files in the other repo) and for min/max of directory length (based on
the max handle length - + 5 for the YYYY plus the '/' and '_').