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

Restrict target_keys object to contain only a single key value pair. #118

Open
wants to merge 1 commit into
base: br-v4.0.1
Choose a base branch
from

Conversation

annakrystalli
Copy link
Member

@annakrystalli annakrystalli commented Dec 18, 2024

This PR resolves #117 by restricting target_keys objects to contain only a single key value pair.

Successful validation is demonstrated in hubAdmin PR hubverse-org/hubAdmin#90 and more specifically in these tests using this and this test file.

Question

Should we also remove target_variable and target_outcome from the schema? These were originally added as standard task ids (and are documented as such in hubDocs) for the following reason:

target_variable/target_outcome: task IDs making up unique identifiers of a two-part target. These tasks can be used in hubs that want to divide the definition of a target across two variables. Both task IDs will be specified as target keys in the target_metadata array.

The answer also therefore has implications on hubverse-org/hubDocs#226

Copy link
Contributor

@elray1 elray1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The content of this PR looks good to me.

I'm commenting here rather than approving because:

  • There is a bit of an unresolved question for me about whether we're going to treat this as a minor version update or a major version update. I think that in the formal sense of semantic versioning, this is probably a major version update because if a hub had been using multiple target keys, they could not simply update to a schema version with this change without breaking. But if there are no existing hubs using multiple target keys, the point is moot and it seems fine to go ahead with the minor version update.
  • The process we discussed in a hubverse devteam meeting a few weeks ago was that we'd email the hubverse mailing list to describe this planned change and check in with existing hubs to see if anyone was using multiple target keys before going through with it (we don't know of anyone who is). I expect that we will do this, but don't want to preempt that process.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Only allow a single target_keys key value pair
2 participants