--- click-reviewers-tools-0.8.orig/clickreviews/cr_desktop.py +++ click-reviewers-tools-0.8/clickreviews/cr_desktop.py @@ -268,7 +268,7 @@ t = 'info' n = 'Exec_webbrowser_webapp (%s)' % (app) s = 'OK' - if not '--webapp' in de.getExec().split(): + if '--webapp' not in de.getExec().split(): t = 'error' s = "could not find --webapp in '%s'" % \ (de.getExec()) @@ -304,7 +304,7 @@ t = 'info' n = 'Exec_webapp_args_minimal_chrome (%s)' % (app) s = 'OK' - if not '--enable-back-forward' in de.getExec().split(): + if '--enable-back-forward' not in de.getExec().split(): t = 'error' s = "could not find --enable-back-forward in '%s'" % \ (de.getExec()) @@ -373,8 +373,9 @@ n = 'Exec_webbrowser_webapp_url_patterns_uses_safe_glob ' + \ '(%s, %s)' % (app, pattern) s = 'OK' - if '*' in pattern[:-1] and (pattern[:-1].count('*') != 1 or - not pattern.startswith('https?://*')): + if '*' in pattern[:-1] and \ + (pattern[:-1].count('*') != 1 or + not pattern.startswith('https?://*')): t = 'warn' s = "'%s' contains nested '*'" % pattern + \ " (needs human review)" @@ -537,8 +538,9 @@ s = 'could not find unity-webaps-*/manifest.json' self._add_result(t, n, s) continue - elif len(manifests) > 1: # for now error on this since having - # multiple manifests is unknown + elif len(manifests) > 1: + # for now error on this since having + # multiple manifests is unknown t = 'error' fns = [] for f in manifests.keys(): --- click-reviewers-tools-0.8.orig/clickreviews/cr_lint.py +++ click-reviewers-tools-0.8/clickreviews/cr_lint.py @@ -520,8 +520,8 @@ t = 'error' s = "(EMAIL NEEDS HUMAN REVIEW) email domain too short: '%s'" \ % self.email - elif len(domain_rev) >= len(pkg_domain_rev): # also '=' to leave - # room for app name + # also '=' to leave room for app name + elif len(domain_rev) >= len(pkg_domain_rev): # Core apps have a long email, domain, but that's all right if self.is_core_app: t = 'info' @@ -544,10 +544,10 @@ if is_special: t = 'warn' s = "email=%s matches special domain=%s" % (self.email, - ".".join(pkg_domain_rev)) + ".".join(pkg_domain_rev)) else: s = "OK (email=%s, package domain=%s)" % (self.email, - ".".join(pkg_domain_rev)) + ".".join(pkg_domain_rev)) else: t = 'error' s = "email=%s does not match package domain=%s " \ @@ -708,8 +708,9 @@ s = 'OK' if len(tmp) >= 3: arch = tmp[2].partition('.click')[0] - if arch == "unknown": # short-circuit here since the appstore - # doesn't determine the version yet + if arch == "unknown": + # short-circuit here since the appstore doesn't determine + # the version yet t = 'info' s = "SKIP: architecture 'unknown'" self._add_result(t, n, s) --- click-reviewers-tools-0.8.orig/clickreviews/cr_online_accounts.py +++ click-reviewers-tools-0.8/clickreviews/cr_online_accounts.py @@ -83,7 +83,7 @@ t = 'info' n = '%s_%s_root' % (app, account_type) s = "OK" - if not account_type in self.accounts[app]: + if account_type not in self.accounts[app]: s = "OK (missing)" self._add_result(t, n, s) continue @@ -136,7 +136,7 @@ t = 'info' n = '%s_%s_root' % (app, account_type) s = "OK" - if not account_type in self.accounts[app]: + if account_type not in self.accounts[app]: s = "OK (missing)" self._add_result(t, n, s) continue @@ -181,7 +181,7 @@ t = 'info' n = '%s_%s' % (app, account_type) s = "OK" - if not account_type in self.accounts[app]: + if account_type not in self.accounts[app]: s = "OK (missing)" self._add_result(t, n, s) continue @@ -221,7 +221,7 @@ t = 'info' n = '%s_%s' % (app, account_type) s = "OK" - if not account_type in self.accounts[app]: + if account_type not in self.accounts[app]: s = "OK (missing)" self._add_result(t, n, s) continue --- click-reviewers-tools-0.8.orig/debian/changelog +++ click-reviewers-tools-0.8/debian/changelog @@ -0,0 +1,122 @@ +click-reviewers-tools (0.8) utopic; urgency=medium + + [ Zoltan Balogh ] + * Give an error if the app is using deprecated Friends API (LP: #1340869) + + [ Martin Albisetti, Daniel Holbach ] + * refactor the way we handle frameworks into a central static list which + should be easy to update. + + [ Jamie Strandboge ] + * updated clickreviews/cr_tests.py for 14.10*dev2 + * bin/repack-click: use -Zgzip when repacking to remain compatible with + debfile (ie, click install) + * warn on new hooks + * implement url-dispatcher hook checks + * implement scope hook checks + * implement content-hub hook checks + * debian/control: Build-Depends and Depends on python3-lxml + * implement account-* hook checks + * redflag the upcoming pay-ui hook + * update security tests to not require apparmor-easyprof-ubuntu or + apparmor-easyprof by using a static list to ease updating + * debian/control: drop Build-Depends and Depends on apparmor-easyprof and + apparmor-easyprof-ubuntu + * update data/apparmor-easyprof-ubuntu.json to not include friends policy + group in 1.2 (LP: #1340869) + * refactor the way we handle apparmor policy into a central static list + which should be easy to update. + * implement push-helper tests (LP: #1346481) + + [ Daniel Holbach ] + * refer to documentation about click in case we encounter .deb packages. + * fix some pep8 warnings. + + -- Daniel Holbach Fri, 25 Jul 2014 16:20:24 +0200 + +click-reviewers-tools (0.7.1) utopic; urgency=medium + + * Merge r198: + [ Jamie Strandboge ] + - ubuntu-scope-local-content template is no longer available. + + -- Daniel Holbach Thu, 05 Jun 2014 16:21:33 +0200 + +click-reviewers-tools (0.7) utopic; urgency=medium + + [ Daniel Holbach ] + * clickreviews/cr_lint.py: add link to more info about "Please use newer + framework". Thanks Alan Pope. + + [ Jamie Strandboge ] + * add 14.10 frameworks. Thanks Martin Albisetti for initial patch + * 13.10 frameworks should be deprecated instead of obsolete and warn when + using deprecated framework + * add click scopes checks + * special case ubuntu-devel-discuss@lists.ubuntu.com + * implement check_hooks() lint tests + * debian/control: Depends on apparmor-easyprof-ubuntu >= 1.2.2 + (LP: #1324121) + + -- Jamie Strandboge Wed, 28 May 2014 23:48:04 +0200 + +click-reviewers-tools (0.6) utopic; urgency=medium + + [ Daniel Holbach ] + * d/control: bump apparmor-easyprof-ubuntu requirement to 1.0.44. + This should safeguard against #1292418 (test-suite failing on saucy). + * clickreviews/cr_desktop.py: check for deprecated execs, add + cordova-ubuntu-2.8 to the list. (LP: #1307533) + + [ Jamie Strandboge ] + * clickreviews/cr_security.py: + - webview policy can be used by webapps + - content_exchange policy can be used by webapps (LP: #1308184) + - clickreviews/tests/test_cr_security.py: tests for above + - warn if webview not used with ubuntu-webapp template on non-13.10 + frameworks + * clickreviews/cr_lint.py: obsolete ubuntu-sdk-13.10 framework + * clickreviews/cr_functional.py: warn if using UbuntuWebView 0.1 + + -- Jamie Strandboge Mon, 28 Apr 2014 13:01:08 -0500 + +click-reviewers-tools (0.5) trusty; urgency=medium + + [ Jamie Strandboge ] + * mock self.supported_policy_versions + * support multiple frameworks on system in security tests + * add/update tests for multiple frameworks in security tests + + -- Daniel Holbach Thu, 27 Feb 2014 15:30:51 +0100 + +click-reviewers-tools (0.4) trusty; urgency=medium + + [ Daniel Holbach ] + * Check for broken icon paths in .desktop files. (LP: #1257429) + * Add initial set of askubuntu answers. + * Add ubuntu-html5-app-launcher to expected_execs. + + [ Jamie Strandboge ] + * Documented and clarified the use of the scripts. + * Fix crash in __del__. (LP: #1282652) + * Add webapp-container tests. + * Document bzr hook to run tests. + + -- Daniel Holbach Wed, 22 Jan 2014 17:59:26 +0100 + +click-reviewers-tools (0.3) trusty; urgency=medium + + * d/compat: bump to 9. + * d/control: + - bump Standards-Version, + - drop X-Python-Version, we have X-Python3-Version, + - programmatical -> programmatic + * d/copyright: fix license mistake (GPL-3+ vs. GPL-3) + + -- Daniel Holbach Wed, 22 Jan 2014 17:38:47 +0100 + +click-reviewers-tools (0.2) trusty; urgency=low + + * Initial release (LP: #1230248) + + -- Daniel Holbach Wed, 25 Sep 2013 14:32:32 +0200 --- click-reviewers-tools-0.8.orig/debian/compat +++ click-reviewers-tools-0.8/debian/compat @@ -0,0 +1 @@ +9 --- click-reviewers-tools-0.8.orig/debian/control +++ click-reviewers-tools-0.8/debian/control @@ -0,0 +1,32 @@ +Source: click-reviewers-tools +Section: devel +Priority: optional +Maintainer: Ubuntu Appstore Developers +Build-Depends: debhelper (>= 9~), + python3-all (>= 3.2~), + python3-apt, + python3-debian, + python3-lxml, + python3-magic, + python3-setuptools, + python3-simplejson, + python3-xdg +Standards-Version: 3.9.5 +Homepage: https://launchpad.net/click-reviewers-tools +Vcs-Bzr: lp:ubuntu-dev-tools +Vcs-Browser: http://bazaar.launchpad.net/~click-reviewers/click-reviewers-tools/trunk/files +X-Python3-Version: >= 3.2 + +Package: click-reviewers-tools +Architecture: all +Depends: python3-apt, + python3-debian, + python3-lxml, + python3-magic, + python3-simplejson, + python3-xdg, + ${misc:Depends}, + ${python3:Depends} +Description: tools to review click packages + These scripts can be used to review click packages both manually and in a + programmatic fashion. --- click-reviewers-tools-0.8.orig/debian/copyright +++ click-reviewers-tools-0.8/debian/copyright @@ -0,0 +1,20 @@ +Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: click-reviewers-tools +Upstream-Contact: Ubuntu App Developers +Source: https://launchpad.net/click-reviewers-tools + +Files: * +Copyright: 2013 Canonical Ltd. +License: GPL-3 + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + . + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + General Public License for more details. + . + On Debian systems, the complete text of the GNU General Public License + version 3 can be found in the /usr/share/common-licenses/GPL-3 file. --- click-reviewers-tools-0.8.orig/debian/docs +++ click-reviewers-tools-0.8/debian/docs @@ -0,0 +1 @@ +README --- click-reviewers-tools-0.8.orig/debian/rules +++ click-reviewers-tools-0.8/debian/rules @@ -0,0 +1,46 @@ +#!/usr/bin/make -f +# -*- makefile -*- + +# Uncomment this to turn on verbose mode. +export DH_VERBOSE=1 + +%: + dh $@ --with python3 --buildsystem pybuild + +PY3REQUESTED := $(shell py3versions -r) +PY3DEFAULT := $(shell py3versions -d) +# Run setup.py with the default python3 last so that the scripts use +# #!/usr/bin/python3 and not #!/usr/bin/python3.X. +PY3 := $(filter-out $(PY3DEFAULT),$(PY3REQUESTED)) python3 + +override_dh_auto_clean: + dh_clean + rm -rf build *.egg-info .pybuild + find -name \*.pyc -print0 | xargs -0r rm -f + find -name __pycache__ -print0 | xargs -0r rm -rf + -$(shell python3 ./bin/update-frameworks ./data/frameworks.json) + -$(shell python3 ./bin/update-apparmor-policy ./data/apparmor-easyprof-ubuntu.json) + +override_dh_auto_build: + dh_auto_build + set -ex; for python in $(PY3); do \ + $$python setup.py build; \ + done + +override_dh_auto_install: + # setuptools likes to leave some debris around, which confuses things. + find build -name \*.pyc -print0 | xargs -0r rm -f + find build -name __pycache__ -print0 | xargs -0r rm -rf + find build -name \*.egg-info -print0 | xargs -0r rm -rf + dh_auto_install + set -ex; for python in $(PY3); do \ + $$python setup.py install --install-layout=deb \ + --root=$(CURDIR)/debian/tmp; \ + done + +ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS))) +override_dh_auto_test: + set -ex; for python in $(PY3); do \ + $$python setup.py test; \ + done +endif