BryanDavis has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/316823

Change subject: jsub: Make trusty the default release target for jsub commands
......................................................................

jsub: Make trusty the default release target for jsub commands

Change the default qsub release target from precise to trusty.

Bug: T143284
Change-Id: I94a908204c520f314bf63f8d41f28407727fc7ed
---
M debian/changelog
M jobutils/bin/jsub
M tests/testsuite.at
3 files changed, 36 insertions(+), 17 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/labs/toollabs 
refs/changes/23/316823/1

diff --git a/debian/changelog b/debian/changelog
index e02cb45..d7ab9a4 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+toollabs (1.16) unstable; urgency=medium
+
+  * jsub: Change default release from Precise to Trusty
+
+ -- Bryan Davis <[email protected]>  Wed, 19 Oct 2016 17:03:14 +0000
+
 toollabs (1.15) unstable; urgency=medium
 
   * jsub: Add warnings for precise deprecation
diff --git a/jobutils/bin/jsub b/jobutils/bin/jsub
index 349ce8c..7555ee0 100755
--- a/jobutils/bin/jsub
+++ b/jobutils/bin/jsub
@@ -33,7 +33,7 @@
 
 
 AVAILABLE_RELEASES = ['precise', 'trusty']
-DEFAULT_RELEASE = 'precise'
+DEFAULT_RELEASE = 'trusty'
 
 
 class NonAbbreviatingArgumentParser(argparse.ArgumentParser):
@@ -613,8 +613,7 @@
         print('*' * 78, file=sys.stderr)
         print(
             'WARNING: No `-l release=...` argument provided.'
-            '\n\tDefault release will change from precise to trusty in '
-            'October 2016.'
+            '\n\tDefault release has changed from precise to trusty!'
             
'\n\thttps://wikitech.wikimedia.org/wiki/Tools_Precise_deprecation',
             file=sys.stderr)
         print('*' * 78, file=sys.stderr)
diff --git a/tests/testsuite.at b/tests/testsuite.at
index 0e268a4..82dd285 100644
--- a/tests/testsuite.at
+++ b/tests/testsuite.at
@@ -74,17 +74,17 @@
 # These tests will create two files (true.err and true.out) in the
 # home directory of the calling user.
 AT_TOOLLABS_JSUB([Normal call], [true], [Your job 501377 ("true") has been 
submitted
-], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=trusty -q task -b yes /bin/true
 ], [], [Your job 501377 ("true") has been submitted
 ], [], [0])
 AT_TOOLLABS_JSUB([Quiet call], [-quiet true], [Your job 501377 ("true") has 
been submitted
-], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=trusty -q task -b yes /bin/true
 ], [], [], [], [0])
 
 # Test that umasks are handled properly.
 AT_SETUP([-o points to a non-existing file])
 _AT_TOOLLABS_JSUB([-o does-not-exist.log -quiet true], [], [Your job 501377 
("true") has been submitted
-], [], [0], [-j no -e $HOME/true.err -o does-not-exist.log -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-j no -e $HOME/true.err -o does-not-exist.log -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=trusty -q task -b yes /bin/true
 ], [], [], [], [0])
 AT_CHECK([stat -c %a does-not-exist.log], [0], [600
 ], [])
@@ -94,7 +94,7 @@
 AT_CHECK([touch does-exist.log], [0], [], [])
 AT_CHECK([chmod 664 does-exist.log], [0], [], [])
 _AT_TOOLLABS_JSUB([-o does-exist.log -quiet true], [], [Your job 501377 
("true") has been submitted
-], [], [0], [-j no -e $HOME/true.err -o does-exist.log -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-j no -e $HOME/true.err -o does-exist.log -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=trusty -q task -b yes /bin/true
 ], [], [], [], [0])
 AT_CHECK([stat -c %a does-exist.log], [0], [664
 ], [])
@@ -102,7 +102,7 @@
 
 AT_SETUP([-o points to a non-existing file and -umask is used])
 _AT_TOOLLABS_JSUB([-o does-not-exist.log -quiet -umask 000 true], [], [Your 
job 501377 ("true") has been submitted
-], [], [0], [-j no -e $HOME/true.err -o does-not-exist.log -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-j no -e $HOME/true.err -o does-not-exist.log -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=trusty -q task -b yes /bin/true
 ], [], [], [], [0])
 AT_CHECK([stat -c %a does-not-exist.log], [0], [666
 ], [])
@@ -112,7 +112,7 @@
 AT_CHECK([touch does-exist.log], [0], [], [])
 AT_CHECK([chmod 664 does-exist.log], [0], [], [])
 _AT_TOOLLABS_JSUB([-o does-exist.log -quiet -umask 000 true], [], [Your job 
501377 ("true") has been submitted
-], [], [0], [-j no -e $HOME/true.err -o does-exist.log -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-j no -e $HOME/true.err -o does-exist.log -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=trusty -q task -b yes /bin/true
 ], [], [], [], [0])
 AT_CHECK([stat -c %a does-exist.log], [0], [664
 ], [])
@@ -121,7 +121,7 @@
 AT_SETUP([-o points to a existing directory])
 AT_CHECK([mkdir does-exist], [0], [], [])
 _AT_TOOLLABS_JSUB([-o does-exist -quiet true], [], [Your job 501377 ("true") 
has been submitted
-], [], [0], [-j no -e $HOME/true.err -o does-exist -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-j no -e $HOME/true.err -o does-exist -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=trusty -q task -b yes /bin/true
 ], [], [], [], [0])
 AT_CHECK([find does-exist -mindepth 1], [0], [], [])
 AT_CLEANUP()
@@ -133,7 +133,7 @@
 -quiet
 -umask 000
 ], [Your job 501377 ("true") has been submitted
-], [], [0], [-j no -e $HOME/true.err -o does-exist.log -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-j no -e $HOME/true.err -o does-exist.log -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=trusty -q task -b yes /bin/true
 ], [], [], [], [0])
 AT_CHECK([stat -c %a does-exist.log], [0], [664
 ], [])
@@ -146,7 +146,7 @@
 -quiet
 -umask 000
 ], [Your job 501377 ("true") has been submitted
-], [], [0], [-j no -e $HOME/true.err -o does-exist.log -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-j no -e $HOME/true.err -o does-exist.log -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=trusty -q task -b yes /bin/true
 ], [], [], [], [0])
 AT_CHECK([stat -c %a does-exist.log], [0], [664
 ], [])
@@ -154,22 +154,36 @@
 
 # Test -l arg handling
 AT_TOOLLABS_JSUB([-l is exploded], [-l foo=1,bar=2 true], [Your job 501377 
("true") has been submitted
-], [], [0], [-l foo=1 -l bar=2 -j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-l foo=1 -l bar=2 -j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=trusty -q task -b yes /bin/true
 ], [], [Your job 501377 ("true") has been submitted
 ], [], [0])
 AT_TOOLLABS_JSUB([-l h_vmem is processed], [-l foo=1,h_vmem=1G,bar=2 true], 
[Your job 501377 ("true") has been submitted
-], [], [0], [-l foo=1 -l bar=2 -j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=1048576k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-l foo=1 -l bar=2 -j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=1048576k -l 
release=trusty -q task -b yes /bin/true
 ], [], [Your job 501377 ("true") has been submitted
 ], [], [0])
 AT_TOOLLABS_JSUB([-l largest wins (virtual_free)], [-l 
h_vmem=1k,virtual_free=1G true], [Your job 501377 ("true") has been submitted
-], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=1153433k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=1153433k -l 
release=trusty -q task -b yes /bin/true
 ], [], [Your job 501377 ("true") has been submitted
 ], [], [0])
 AT_TOOLLABS_JSUB([-l largest wins (h_vmem)], [-l h_vmem=1g,virtual_free=1K 
true], [Your job 501377 ("true") has been submitted
-], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=1048576k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=1048576k -l 
release=trusty -q task -b yes /bin/true
 ], [], [Your job 501377 ("true") has been submitted
 ], [], [0])
 AT_TOOLLABS_JSUB([-l largest wins (default)], [-l h_vmem=1m,virtual_free=1M 
true], [Your job 501377 ("true") has been submitted
-], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=precise -q task -b yes /bin/true
+], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=trusty -q task -b yes /bin/true
 ], [], [Your job 501377 ("true") has been submitted
 ], [], [0])
+
+# Test release
+AT_TOOLLABS_JSUB([-l release=precise], [-l release=precise true], [Your job 
501377 ("true") has been submitted
+], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=precise -q task -b yes /bin/true
+], [], [Your job 501377 ("true") has been submitted
+AT_TOOLLABS_JSUB([-release precise], [-release precise true], [Your job 501377 
("true") has been submitted
+], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=precise -q task -b yes /bin/true
+], [], [Your job 501377 ("true") has been submitted
+AT_TOOLLABS_JSUB([-l release=trusty], [-l release=trusty true], [Your job 
501377 ("true") has been submitted
+], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=trusty -q task -b yes /bin/true
+], [], [Your job 501377 ("true") has been submitted
+AT_TOOLLABS_JSUB([-release trusty], [-release trusty true], [Your job 501377 
("true") has been submitted
+], [], [0], [-j no -e $HOME/true.err -o $HOME/true.out -M 
${LOGNAME:-$USER}@tools.wmflabs.org -N true -hard -l h_vmem=524288k -l 
release=trusty -q task -b yes /bin/true
+], [], [Your job 501377 ("true") has been submitted

-- 
To view, visit https://gerrit.wikimedia.org/r/316823
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I94a908204c520f314bf63f8d41f28407727fc7ed
Gerrit-PatchSet: 1
Gerrit-Project: labs/toollabs
Gerrit-Branch: master
Gerrit-Owner: BryanDavis <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to