Merge lp:~percona-toolkit-dev/percona-toolkit/not-all-scripts-recognize-no-version-check-1361293 into lp:~percona-toolkit-dev/percona-toolkit/release-2.2.12
Status: | Merged | ||||
---|---|---|---|---|---|
Merged at revision: | 629 | ||||
Proposed branch: | lp:~percona-toolkit-dev/percona-toolkit/not-all-scripts-recognize-no-version-check-1361293 | ||||
Merge into: | lp:~percona-toolkit-dev/percona-toolkit/release-2.2.12 | ||||
Diff against target: |
402 lines (+141/-27) 17 files modified
bin/pt-align (+8/-0) bin/pt-fifo-split (+8/-0) bin/pt-fingerprint (+8/-0) bin/pt-ioprofile (+4/-1) bin/pt-mext (+29/-23) bin/pt-mysql-summary (+2/-0) bin/pt-pmp (+4/-1) bin/pt-show-grants (+8/-0) bin/pt-sift (+4/-1) bin/pt-slave-find (+8/-0) bin/pt-stalk (+4/-1) bin/pt-summary (+2/-0) bin/pt-table-usage (+8/-0) bin/pt-visual-explain (+8/-0) lib/OptionParser.pm (+10/-0) lib/bash/parse_options.sh (+3/-0) t/lib/OptionParser.t (+23/-0) |
||||
To merge this branch: | bzr merge lp:~percona-toolkit-dev/percona-toolkit/not-all-scripts-recognize-no-version-check-1361293 | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Daniel Nichter | Needs Fixing | ||
Review via email: mp+237832@code.launchpad.net |
Description of the change
Problem:
When option no-version-check was put in a global configuration file (to avoid unwanted internet connection) , many tools failed as they did not recognize the option.
Fix:
Bash tools were instructed to silently ignore it if it was read from a config file (none does version-check right now)
Perl tools were instructed to ignore it if it was read from a config file AND it was unsupported.
Modification was done on OptionParser.pm and parse_options.sh , and updated to the rest of the tools.
Note:
pt-mext bash script had differences with it's embedded parse_options module ( the _parse_pod function seemed to pipe the source file through a perl code, rather than having the perl code open and read the file ) ... but nevertheless after updating tests ran ok.
In the comments there's a question and a minor style change for a line in parse_options.sh.