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

Handle wrong/missing job dependencies appropriately #1311

Merged
merged 2 commits into from May 8, 2017

Conversation

Martchus
Copy link
Contributor

@Martchus Martchus commented May 3, 2017

my $settings = $job->settings_hash;
for my $depname ('START_AFTER_TEST', 'PARALLEL_WITH') {
for my $dependency (
{'START_AFTER_TEST', OpenQA::Schema::Result::JobDependencies::CHAINED},
Copy link
Contributor

Choose a reason for hiding this comment

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

if you mean to write a hash, write a hash - i.e. as START_AFTER_TEST =>

Copy link
Contributor Author

@Martchus Martchus May 3, 2017

Choose a reason for hiding this comment

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

I mean to write a tuple, but there are no tuples in Perl. So square brackets to emulate tuple with an array and then my ($depname, $deptype) = @$dependency;?

* Make the t/api/02-iso.t no longer depend on jobs being scheduled
  despite wrong dependencies
* Prevent warnings printed when starting tests with `prove -v`
   * `START_AFTER_TEST=kde:32bit not found - check for typos and dependency cycles`
   * `START_AFTER_TEST=textmode:64bit not found - check for typos and dependency cycles`
@codecov
Copy link

codecov bot commented May 3, 2017

Codecov Report

Merging #1311 into master will decrease coverage by 0.01%.
The diff coverage is 92.85%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master   #1311      +/-   ##
=========================================
- Coverage   87.21%   87.2%   -0.02%     
=========================================
  Files         104     104              
  Lines        7354    7363       +9     
=========================================
+ Hits         6414    6421       +7     
- Misses        940     942       +2
Impacted Files Coverage Δ
lib/OpenQA/WebAPI/Controller/API/V1/Iso.pm 93.18% <92.85%> (+0.24%) ⬆️
lib/OpenQA/Worker/Jobs.pm 83.41% <0%> (-0.5%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 67904cb...999b3e6. Read the comment docs.

* Show error messages in web UI
* Abort scheduling jobs if dependencies wrong/missing

See https://progress.opensuse.org/issues/10902
@coolo coolo merged commit 9869466 into os-autoinst:master May 8, 2017
@Martchus Martchus deleted the fix/jobdepends branch May 8, 2017 10:27
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

2 participants