move DS validation from hard-coded to function driven#392
move DS validation from hard-coded to function driven#392couthcommander wants to merge 1 commit intomainfrom
Conversation
|
Here's an example - the old approach: incomplete approach: The final approach would replace all instances of "REDCAP_SYSTEM_FIELDS" with |
|
@couthcommander I changed this to a draft PR. |
|
@nutterb thoughts? The existing structure is easier but will grow increasingly complex over time. This is to make it driven by an editable configuration file. |
|
Ignore my previous comment. For some reason I thought @couthcommander 's work used a json file somewhere. And then proceeded to describe exactly what he has coded. I think I might be sleep deprived. But yes, I think this is a necessary change. And having independently determined that this approach would be a feasible strategy, I'm on board with it. |
|
I'm ready for this to move from draft to being considered. |
This PR is to create a discussion. do not merge
Rather than hard-code validation into vectors/data.frames (which will not support branching logic with version), the code in "redcapDataStructure" could be updated into functions. This could grow into something very difficult to maintain. I have an incomplete version to at least start a dialogue about the best approach. I have moved the hard-coded information into a CSV file.