Enable BytesWarnings. master
authorArfrever Frehtes Taifersar Arahesis <Arfrever@Apache.Org>
Sat, 18 Jan 2014 11:38:31 +0000 (12:38 +0100)
committerArfrever Frehtes Taifersar Arahesis <Arfrever@Apache.Org>
Sat, 18 Jan 2014 11:38:31 +0000 (12:38 +0100)
33 files changed:
bin/archive-conf
bin/binhost-snapshot
bin/check-implicit-pointer-usage.py
bin/chpathtool.py
bin/clean_locks
bin/dispatch-conf
bin/dohtml.py
bin/ebuild
bin/ebuild-ipc.py
bin/egencache
bin/emaint
bin/emerge
bin/emirrordist
bin/env-update
bin/filter-bash-environment.py
bin/fixpackages
bin/glsa-check
bin/install.py
bin/lock-helper.py
bin/portageq
bin/quickpkg
bin/regenworld
bin/repoman
bin/xattr-helper.py
bin/xpak-helper.py
pym/portage/tests/dbapi/test_portdb_cache.py
pym/portage/tests/emerge/test_emerge_slot_abi.py
pym/portage/tests/emerge/test_simple.py
pym/portage/tests/repoman/test_simple.py
pym/portage/tests/runTests
pym/portage/tests/util/test_whirlpool.py
runtests.sh
tabcheck.py

index 2c34588c91610b6fb63a438fdc8ba5e65bc46ed6..f513ff8d0ab9d35a71a8bc299f036fd0161b3b23 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 1999-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 #
 # Distributed under the terms of the GNU General Public License v2
 
 #
index 376080c05acea62f0cb937de27fc55b755ec71eb..1a140202f9fe171f63b1ef4983891efb0ba82daf 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 2010-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 2010-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 import io
 # Distributed under the terms of the GNU General Public License v2
 
 import io
@@ -31,7 +31,7 @@ def parse_args(argv):
 
        usage += "\n\n"
        for line in textwrap.wrap(prog_desc, 70):
 
        usage += "\n\n"
        for line in textwrap.wrap(prog_desc, 70):
-               usage += line + "\n" 
+               usage += line + "\n"
 
        usage += "\n"
        usage += "Required Arguments:\n\n"
 
        usage += "\n"
        usage += "Required Arguments:\n\n"
index 8822c4504eac43d74eb884143a214881dc674603..863c3126fce8a7ba4775c45dab70cd68f1b29397 100755 (executable)
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/python -bb
 
 # Ripped from HP and updated from Debian
 # Update by Gentoo to support unicode output
 
 # Ripped from HP and updated from Debian
 # Update by Gentoo to support unicode output
index 287644d4b7dedd1745d2598353b3a03a538a18ec..f5b2c67db8399712dae62b6bbc56fdd254cdb083 100755 (executable)
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/python -bb
 # Copyright 2011-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 # Copyright 2011-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
index 184e80cb40f97fe5aca3735bdbcd8c7016af49f3..7d1040923b3ca1960880e6f59df1b8510fa993e7 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python -O
-# Copyright 1999-2013 Gentoo Foundation
+#!/usr/bin/python -bbO
+# Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
@@ -22,11 +22,11 @@ if not sys.argv[1:] or "--help" in sys.argv or "-h" in sys.argv:
        print("%s --force %s/.locks" % (sys.argv[0], portage.settings["DISTDIR"]))
        print()
        sys.exit(1)
        print("%s --force %s/.locks" % (sys.argv[0], portage.settings["DISTDIR"]))
        print()
        sys.exit(1)
-       
+
 force = False
 if "--force" in sys.argv[1:]:
        force=True
 force = False
 if "--force" in sys.argv[1:]:
        force=True
-       
+
 for x in sys.argv[1:]:
        if x == "--force":
                continue
 for x in sys.argv[1:]:
        if x == "--force":
                continue
@@ -34,7 +34,7 @@ for x in sys.argv[1:]:
                for y in portage.locks.hardlock_cleanup(x, remove_all_locks=force):
                        print(y)
                print()
                for y in portage.locks.hardlock_cleanup(x, remove_all_locks=force):
                        print(y)
                print()
-               
+
        except OSError as e:
                if e.errno in (errno.ENOENT, errno.ENOTDIR):
                        print("!!! %s is not a directory or does not exist" % x)
        except OSError as e:
                if e.errno in (errno.ENOENT, errno.ENOTDIR):
                        print("!!! %s is not a directory or does not exist" % x)
index 10455f444633d6737035d26871fd08fb5c54f484..6a818bf3bc7f1693b5c29327f4b14d054fbce8d0 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python -O
-# Copyright 1999-2013 Gentoo Foundation
+#!/usr/bin/python -bbO
+# Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 #
 # Distributed under the terms of the GNU General Public License v2
 
 #
index f98557f6179f1b996a2e09bbdd5dda753f639e10..1b8c92580d6ec646d63b00809077d27405d776c4 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 1999-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 #
 # Distributed under the terms of the GNU General Public License v2
 
 #
index 262dab6d87f0d4e367d0f8a0971c004c32b98ded..2138aed33c4e22ce278ab03787178cb1b1363667 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python -O
-# Copyright 1999-2013 Gentoo Foundation
+#!/usr/bin/python -bbO
+# Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
index d351e9454442c1a1c6f5aeb11656dd4509e00356..bbb6e864315c381c91698345c455b4de403df04c 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 2010-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 2010-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 #
 # This is a helper which ebuild processes can use
 # Distributed under the terms of the GNU General Public License v2
 #
 # This is a helper which ebuild processes can use
@@ -150,7 +150,7 @@ class EbuildIpc(object):
                                        self._no_daemon_msg()
                                        return 2
 
                                        self._no_daemon_msg()
                                        return 2
 
-               buf = pipe_reader.getvalue() 
+               buf = pipe_reader.getvalue()
 
                retval = 2
 
 
                retval = 2
 
index 9b22363f061c9a61182224badfffd3dcd3885b5e..2562d59fc84793765f4271f24cc61f596fb505cc 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 2009-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 2009-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 # unicode_literals for compat with TextIOWrapper in Python 2
 # Distributed under the terms of the GNU General Public License v2
 
 # unicode_literals for compat with TextIOWrapper in Python 2
index adf44d0dff2a8d712c028b0b4fac0efcd971ce2d..c5415c3e3e2418533c018d70d28794f273d225d2 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python -O
-# Copyright 2005-2013 Gentoo Foundation
+#!/usr/bin/python -bbO
+# Copyright 2005-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 """System health checks and maintenance utilities.
 # Distributed under the terms of the GNU General Public License v2
 
 """System health checks and maintenance utilities.
index 4d9ea5a13d56ac1e419320e82dd53aaa6f621530..a415afa3029506b92da0ca230f84e3278e41b3d7 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 2006-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 2006-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
index 8d93de9c0d7e33a12695ef8c4a0314b87ce026d0..2430aa7bd7e1c77d5421639396d60a508d53ddbd 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 2013-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 import sys
 # Distributed under the terms of the GNU General Public License v2
 
 import sys
index b500c545cc536f582276789b24a1f1eca2ce358a..8e3b81cbf0053331a36894d38058a04fd883f4e1 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python -O
-# Copyright 1999-2013 Gentoo Foundation
+#!/usr/bin/python -bbO
+# Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
index 3d4b3ecbb1203655326ab286716f2f1f5d652645..838b422f7ba08773f08c7fe52f24af1c15c369e1 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 1999-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 import codecs
 # Distributed under the terms of the GNU General Public License v2
 
 import codecs
index e29d6eeffb7bc07cff42e64a06f07051f38676d5..3ec28321fbc581f609b54a59e2fe5156b5aff6a5 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 1999-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
index 7fa3688aaaedde7a6e20fc46b777e40de4cd5918..87eafca47d9d162e26e1561de823a247c866ea9f 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 2008-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 2008-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
@@ -244,7 +244,7 @@ if mode in ["dump", "fix", "inject", "pretend"]:
                                mergedict = {}
                                for (vuln, update) in myglsa.getAffectionTable(least_change=least_change):
                                        mergedict.setdefault(update, []).append(vuln)
                                mergedict = {}
                                for (vuln, update) in myglsa.getAffectionTable(least_change=least_change):
                                        mergedict.setdefault(update, []).append(vuln)
-                               
+
                                sys.stdout.write(">>> The following updates will be performed for this GLSA:\n")
                                for pkg in mergedict:
                                        if pkg != "":
                                sys.stdout.write(">>> The following updates will be performed for this GLSA:\n")
                                for pkg in mergedict:
                                        if pkg != "":
index 2c6dfbe96fd6637eef5ddcd85e13f40ce642d1de..423ee42f24961900871f8bd77747cf6668559391 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 2013-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 import os
 # Distributed under the terms of the GNU General Public License v2
 
 import os
@@ -61,7 +61,7 @@ def parse_args(args):
        parser.add_argument(
                "--owner",
                "-o",
        parser.add_argument(
                "--owner",
                "-o",
-               action="store", 
+               action="store",
                dest="owner"
        )
        parser.add_argument(
                dest="owner"
        )
        parser.add_argument(
index 128e4ddd0fa20f4e23e4ba70e89b359bdc6f7d60..0c218352ed16d8629e0d3b9e9d9f6e71b8fe0cd9 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 2010-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 2010-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 import os
 # Distributed under the terms of the GNU General Public License v2
 
 import os
index a50b8055c752d00973171c5005faf74eb750d9f2..59cc01953d789c4a5119b2783455f4dca24d51ff 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python -O
-# Copyright 1999-2013 Gentoo Foundation
+#!/usr/bin/python -bbO
+# Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function, unicode_literals
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function, unicode_literals
index cf5800c2ef7a1c8e6fe2547839b6269d6b84ace9..a3e2f5b20e394cdd69cf9cbe15417283890b96ff 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 1999-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
index f74b3dde06d42c052e446caf23578a97b3d35359..239ea9a466510aa8fca530485763df89885869ef 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 1999-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
 # Distributed under the terms of the GNU General Public License v2
 
 from __future__ import print_function
index d1542e96bc9e21d6abda3efd29e8ffb53bb3753e..1277f3644e64210b6e0ba3277589aee38e5d0ac1 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python -O
-# Copyright 1999-2013 Gentoo Foundation
+#!/usr/bin/python -bbO
+# Copyright 1999-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 # Next to do: dep syntax checking in mask files
 # Distributed under the terms of the GNU General Public License v2
 
 # Next to do: dep syntax checking in mask files
index 6d99521af3ab5a9854e5fbd9145a742ef399b77c..6525393c22890ac67575edc219cb3d49b2d86dac 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 2012-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 2012-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 """Dump and restore extended attributes.
 # Distributed under the terms of the GNU General Public License v2
 
 """Dump and restore extended attributes.
index d9d325d59e22a96863aa4f27f2ba051338669b08..9fdc8ce8e31cfe124e3b600edf870c585412c9fb 100755 (executable)
@@ -1,5 +1,5 @@
-#!/usr/bin/python
-# Copyright 2009-2013 Gentoo Foundation
+#!/usr/bin/python -bb
+# Copyright 2009-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 import sys
 # Distributed under the terms of the GNU General Public License v2
 
 import sys
index 98439629d1ec9cee93b1595134a8fbcefb896f03..e04d8de4039f68330b162350b2979c38c579d2c9 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 2012-2013 Gentoo Foundation
+# Copyright 2012-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 import subprocess
 # Distributed under the terms of the GNU General Public License v2
 
 import subprocess
@@ -37,11 +37,11 @@ class PortdbCacheTestCase(TestCase):
                layout_conf_path = os.path.join(metadata_dir, "layout.conf")
 
                portage_python = portage._python_interpreter
                layout_conf_path = os.path.join(metadata_dir, "layout.conf")
 
                portage_python = portage._python_interpreter
-               egencache_cmd = (portage_python, "-Wd",
+               egencache_cmd = (portage_python, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "egencache"),
                        "--repo", "test_repo",
                        "--repositories-configuration", settings.repositories.config_string())
                        os.path.join(PORTAGE_BIN_PATH, "egencache"),
                        "--repo", "test_repo",
                        "--repositories-configuration", settings.repositories.config_string())
-               python_cmd = (portage_python, "-Wd", "-c")
+               python_cmd = (portage_python, "-bb", "-Wd", "-c")
 
                test_commands = (
                        (lambda: not os.path.exists(pms_cache_dir),),
 
                test_commands = (
                        (lambda: not os.path.exists(pms_cache_dir),),
@@ -84,17 +84,17 @@ class PortdbCacheTestCase(TestCase):
                                        sys.exit(1)
                        """),),
 
                                        sys.exit(1)
                        """),),
 
-                       # Don't use python -Wd, since the pms format triggers deprecation warnings
+                       # Disable DeprecationWarnings, since the pms format triggers them
                        # in portdbapi._create_pregen_cache().
                        (BASH_BINARY, "-c", "echo %s > %s" %
                                tuple(map(portage._shell_quote,
                                ("cache-formats = pms md5-dict", layout_conf_path,)))),
                        # in portdbapi._create_pregen_cache().
                        (BASH_BINARY, "-c", "echo %s > %s" %
                                tuple(map(portage._shell_quote,
                                ("cache-formats = pms md5-dict", layout_conf_path,)))),
-                       (portage_python, "-Wi", "-c") + (textwrap.dedent("""
+                       (portage_python, "-bb", "-Wd", "-Wi::DeprecationWarning", "-c") + (textwrap.dedent("""
                                import os, sys, portage
                                if portage.portdb.porttree_root not in portage.portdb._pregen_auxdb:
                                        sys.exit(1)
                        """),),
                                import os, sys, portage
                                if portage.portdb.porttree_root not in portage.portdb._pregen_auxdb:
                                        sys.exit(1)
                        """),),
-                       (portage_python, "-Wi", "-c") + (textwrap.dedent("""
+                       (portage_python, "-bb", "-Wd", "-Wi::DeprecationWarning", "-c") + (textwrap.dedent("""
                                import os, sys, portage
                                from portage.cache.metadata import database as pms_database
                                if not isinstance(portage.portdb._pregen_auxdb[portage.portdb.porttree_root], pms_database):
                                import os, sys, portage
                                from portage.cache.metadata import database as pms_database
                                if not isinstance(portage.portdb._pregen_auxdb[portage.portdb.porttree_root], pms_database):
index 7d8426b9b991eb0f1390d3a4805c7f100e1292af..e73ebc50c630f53ca34a6df735d38deea0473741 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 2012-2013 Gentoo Foundation
+# Copyright 2012-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 import subprocess
 # Distributed under the terms of the GNU General Public License v2
 
 import subprocess
@@ -69,9 +69,9 @@ class SlotAbiEmergeTestCase(TestCase):
                package_mask_path = os.path.join(user_config_dir, "package.mask")
 
                portage_python = portage._python_interpreter
                package_mask_path = os.path.join(user_config_dir, "package.mask")
 
                portage_python = portage._python_interpreter
-               ebuild_cmd = (portage_python, "-Wd",
+               ebuild_cmd = (portage_python, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "ebuild"))
                        os.path.join(PORTAGE_BIN_PATH, "ebuild"))
-               emerge_cmd = (portage_python, "-Wd",
+               emerge_cmd = (portage_python, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "emerge"))
 
                test_ebuild = portdb.findname("dev-libs/dbus-glib-0.98")
                        os.path.join(PORTAGE_BIN_PATH, "emerge"))
 
                test_ebuild = portdb.findname("dev-libs/dbus-glib-0.98")
index ad02384a823c70f6c419d983da1b9f11d6a1a8d8..2016ae69fae945c47ec19be1178b18d7338f81e2 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 2011-2013 Gentoo Foundation
+# Copyright 2011-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 import subprocess
 # Distributed under the terms of the GNU General Public License v2
 
 import subprocess
@@ -174,29 +174,29 @@ pkg_preinst() {
                cachedir_pregen = os.path.join(test_repo_location, "metadata", "md5-cache")
 
                portage_python = portage._python_interpreter
                cachedir_pregen = os.path.join(test_repo_location, "metadata", "md5-cache")
 
                portage_python = portage._python_interpreter
-               dispatch_conf_cmd = (portage_python, "-Wd",
+               dispatch_conf_cmd = (portage_python, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "dispatch-conf"))
                        os.path.join(PORTAGE_BIN_PATH, "dispatch-conf"))
-               ebuild_cmd = (portage_python, "-Wd",
+               ebuild_cmd = (portage_python, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "ebuild"))
                        os.path.join(PORTAGE_BIN_PATH, "ebuild"))
-               egencache_cmd = (portage_python, "-Wd",
+               egencache_cmd = (portage_python, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "egencache"),
                        "--repo", "test_repo",
                        "--repositories-configuration", settings.repositories.config_string())
                        os.path.join(PORTAGE_BIN_PATH, "egencache"),
                        "--repo", "test_repo",
                        "--repositories-configuration", settings.repositories.config_string())
-               emerge_cmd = (portage_python, "-Wd",
+               emerge_cmd = (portage_python, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "emerge"))
                        os.path.join(PORTAGE_BIN_PATH, "emerge"))
-               emaint_cmd = (portage_python, "-Wd",
+               emaint_cmd = (portage_python, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "emaint"))
                        os.path.join(PORTAGE_BIN_PATH, "emaint"))
-               env_update_cmd = (portage_python, "-Wd",
+               env_update_cmd = (portage_python, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "env-update"))
                etc_update_cmd = (BASH_BINARY,
                        os.path.join(PORTAGE_BIN_PATH, "etc-update"))
                        os.path.join(PORTAGE_BIN_PATH, "env-update"))
                etc_update_cmd = (BASH_BINARY,
                        os.path.join(PORTAGE_BIN_PATH, "etc-update"))
-               fixpackages_cmd = (portage_python, "-Wd",
+               fixpackages_cmd = (portage_python, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "fixpackages"))
                        os.path.join(PORTAGE_BIN_PATH, "fixpackages"))
-               portageq_cmd = (portage_python, "-Wd",
+               portageq_cmd = (portage_python, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "portageq"))
                        os.path.join(PORTAGE_BIN_PATH, "portageq"))
-               quickpkg_cmd = (portage_python, "-Wd",
+               quickpkg_cmd = (portage_python, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "quickpkg"))
                        os.path.join(PORTAGE_BIN_PATH, "quickpkg"))
-               regenworld_cmd = (portage_python, "-Wd",
+               regenworld_cmd = (portage_python, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "regenworld"))
 
                rm_binary = find_binary("rm")
                        os.path.join(PORTAGE_BIN_PATH, "regenworld"))
 
                rm_binary = find_binary("rm")
index 23b0e0a4538f21f64f753e41a23339b11244fe41..9fc6d83543b189cb255eddfca885dcb8295f0456 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 2011-2013 Gentoo Foundation
+# Copyright 2011-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 import subprocess
 # Distributed under the terms of the GNU General Public License v2
 
 import subprocess
@@ -170,7 +170,7 @@ class SimpleRepomanTestCase(TestCase):
                profiles_dir = os.path.join(test_repo_location, "profiles")
                license_dir = os.path.join(test_repo_location, "licenses")
 
                profiles_dir = os.path.join(test_repo_location, "profiles")
                license_dir = os.path.join(test_repo_location, "licenses")
 
-               repoman_cmd = (portage._python_interpreter, "-Wd",
+               repoman_cmd = (portage._python_interpreter, "-bb", "-Wd",
                        os.path.join(PORTAGE_BIN_PATH, "repoman"))
 
                git_binary = find_binary("git")
                        os.path.join(PORTAGE_BIN_PATH, "repoman"))
 
                git_binary = find_binary("git")
@@ -287,8 +287,7 @@ class SimpleRepomanTestCase(TestCase):
 
                        for cwd in ("", "dev-libs", "dev-libs/A", "dev-libs/B"):
                                abs_cwd = os.path.join(test_repo_symlink, cwd)
 
                        for cwd in ("", "dev-libs", "dev-libs/A", "dev-libs/B"):
                                abs_cwd = os.path.join(test_repo_symlink, cwd)
-                               proc = subprocess.Popen([portage._python_interpreter, "-Wd",
-                                       os.path.join(PORTAGE_BIN_PATH, "repoman"), "full"],
+                               proc = subprocess.Popen(repoman_cmd + ("full",),
                                        cwd=abs_cwd, env=env, stdout=stdout)
 
                                if debug:
                                        cwd=abs_cwd, env=env, stdout=stdout)
 
                                if debug:
index 60bcf31b70ad056857299bc1c8ae5b115f80baa6..5869f37774e92ce7f9f87db0bf4de543a500146a 100755 (executable)
@@ -1,6 +1,6 @@
-#!/usr/bin/python -Wd
+#!/usr/bin/python -bbWd
 # runTests.py -- Portage Unit Test Functionality
 # runTests.py -- Portage Unit Test Functionality
-# Copyright 2006-2013 Gentoo Foundation
+# Copyright 2006-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 import os, sys
 # Distributed under the terms of the GNU General Public License v2
 
 import os, sys
index dd0de899a606ad88d9135d82c3701edc388fe79b..ac78d9742130d35f65f9d5c1f25dae79a3074466 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 2011 Gentoo Foundation
+# Copyright 2011-2014 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 import subprocess
 # Distributed under the terms of the GNU General Public License v2
 
 import subprocess
@@ -11,6 +11,6 @@ from portage.tests import TestCase
 class WhirlpoolTestCase(TestCase):
        def testBundledWhirlpool(self):
                # execute the tests bundled with the whirlpool module
 class WhirlpoolTestCase(TestCase):
        def testBundledWhirlpool(self):
                # execute the tests bundled with the whirlpool module
-               retval = subprocess.call([portage._python_interpreter, "-Wd",
+               retval = subprocess.call([portage._python_interpreter, "-bb", "-Wd",
                        os.path.join(PORTAGE_PYM_PATH, "portage/util/whirlpool.py")])
                self.assertEqual(retval, os.EX_OK)
                        os.path.join(PORTAGE_PYM_PATH, "portage/util/whirlpool.py")])
                self.assertEqual(retval, os.EX_OK)
index c759ae9cb0405fa8ff6fcd2bc9041ac7e3377a37..1bd1234a81c020bb0f3860d2162ab3dc5a87ce73 100755 (executable)
@@ -67,7 +67,7 @@ for version in ${PYTHON_VERSIONS}; do
        fi
        if [[ -x "${executable}" ]]; then
                echo -e "${GOOD}Testing with Python ${version}...${NORMAL}"
        fi
        if [[ -x "${executable}" ]]; then
                echo -e "${GOOD}Testing with Python ${version}...${NORMAL}"
-               "${executable}" -Wd pym/portage/tests/runTests "$@"
+               "${executable}" -bb -Wd pym/portage/tests/runTests "$@"
                status=$?
                status_array[${#status_array[@]}]=${status}
                found_versions[${#found_versions[@]}]=${version}
                status=$?
                status_array[${#status_array[@]}]=${status}
                found_versions[${#found_versions[@]}]=${version}
index 1699e9883a859103256d439a9a39b5001569938a..7b5ea19136f35d2712c2d0c8418083e935a00733 100755 (executable)
@@ -1,4 +1,4 @@
-#!/usr/bin/python -O
+#!/usr/bin/python -bbO
 
 import tabnanny,sys
 
 
 import tabnanny,sys