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

Debug double %{dist} #411

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -765,10 +765,10 @@ pipeline {
git commit -m "Update pipeline-lib branch to self''' +
(cachedCommitPragma('Test-skip-build', 'true') == 'true' ? '' :
'\n\nSkip-unit-tests: true') + '''" Jenkinsfile
git push -f origin $branch_name:$branch_name
else
git show
fi
git push -f origin $branch_name:$branch_name
sleep 10'''
sh label: 'Delete local test branch',
script: '''dir="daos-''' + env.TEST_BRANCH.replaceAll('/', '-') + '''"
Expand Down
10 changes: 10 additions & 0 deletions vars/daosPackagesVersion.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ String call(String distro, String next_version) {
String target_branch = env.CHANGE_TARGET ? env.CHANGE_TARGET : env.BRANCH_NAME
String _distro = distro

println('daosPackagesVersion(' + _distro + ', ' + next_version + ')')

// build parameter (CI_RPM_TEST_VERSION) has highest priority, followed by commit pragma
// TODO: this should actually be determined from the PR-repos artifacts
String version = rpmTestVersion()
Expand All @@ -52,14 +54,19 @@ String call(String distro, String next_version) {
}

if (target_branch =~ testBranchRE()) {
println(target_branch + ' =~ ' + testBranchRE())
// weekly-test just wants the latest for the branch
if (rpm_version_cache != '' && rpm_version_cache != 'locked') {
println('1: rpm_version_cache == ' + rpm_version_cache )
println('1: rpmDistValue(' + _distro + ') == ' + rpmDistValue(_distro))
return rpm_version_cache + rpmDistValue(_distro)
}
if (rpm_version_cache == '') {
// no cached value and nobody's getting it
rpm_version_cache = 'locked'
println('calling daosLatestVersion(' + next_version + ', ' + _distro + ')')
rpm_version_cache = daosLatestVersion(next_version, _distro)
println('rpm_version_cache == ' + rpm_version_cache)
} else {
// somebody else is getting it, wait for them
Integer i = 30
Expand All @@ -71,8 +78,11 @@ String call(String distro, String next_version) {
rpm_version_cache = daosLatestVersion(next_version, _distro)
}
}
println('2: rpm_version_cache == ' + rpm_version_cache )
println('2: rpmDistValue(' + _distro + ') == ' + rpmDistValue(_distro))
return rpm_version_cache + rpmDistValue(_distro)
}
println(target_branch + ' !~ ' + testBranchRE())

/* what's the query to get the highest 1.0.x package?
if (target_branch == "weekly-testing-1.x") {
Expand Down