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

Make --skip-deps and --skip-chained-deps work as described in the docs #5026

Merged
merged 1 commit into from Mar 3, 2023

Conversation

kraih
Copy link
Member

@kraih kraih commented Mar 3, 2023

The documentation says that --skip-deps and --skip-chained-deps only affects parent jobs. But in the code both flags were applied unconditionally to all dependencies, no matter if --clone-children was present as well.

With this patch applied you can use --skip-deps --clone-children to clone a job with its children, but without parents.

The documentation was added 7 years ago, together with the dependency cloning feature, which at the time only allowed parents to be cloned. 4 years later another feature was introduced that allows for child jobs to be cloned as well. Here it appears the old documentation was missed, and has been incorrect since then.

Clone dependencies: 39cbc40
Clone children: 7cb28ed

Progress: https://progress.opensuse.org/issues/124493

The documentation says that `--skip-deps` and `--skip-chained-deps`
only affects parent jobs. But in the code both flags were applied
unconditionally to all dependencies, no matter if `--clone-children` was
present as well.

With this patch applied you can use `--skip-deps --clone-children` to
clone a job with its children, but without parents.

The documentation was added 7 years ago, together with the dependency
cloning feature, which at the time only allowed parents to be cloned.
4 years later another feature was introduced that allows for child jobs
to be cloned as well. Here it appears the old documentation was missed,
and has been incorrect since then.

Clone dependencies: 39cbc40
Clone children: 7cb28ed

Progress: https://progress.opensuse.org/issues/124493
Copy link
Contributor

@Martchus Martchus left a comment

Choose a reason for hiding this comment

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

Thanks for making sense of what has happened before. Good that the change turned out rather simple (supposedly the tests were the hard part).

@codecov
Copy link

codecov bot commented Mar 3, 2023

Codecov Report

Merging #5026 (5571f53) into master (f74fdc6) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master    #5026   +/-   ##
=======================================
  Coverage   98.19%   98.19%           
=======================================
  Files         379      379           
  Lines       35570    35592   +22     
=======================================
+ Hits        34929    34951   +22     
  Misses        641      641           
Impacted Files Coverage Δ
lib/OpenQA/Script/CloneJob.pm 97.15% <100.00%> (ø)
t/35-script_clone_job.t 100.00% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@mergify mergify bot merged commit c495768 into master Mar 3, 2023
@mergify mergify bot deleted the k/clone_jobs branch March 3, 2023 16:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants