Repository: pypa/virtualenv

Issue:
automate release process
we'll release on git tag push from within the CI (if all tests pass) via a role account


Discussion:

Resolving patch:
diff --git a/virtualenv.py b/virtualenv.py
--- a/virtualenv.py
+++ b/virtualenv.py
@@ -40,7 +40,7 @@
     # noinspection PyPep8Naming
     import configparser as ConfigParser
 
-__version__ = "16.2.0.dev0"
+__version__ = "16.2.0"
 virtualenv_version = __version__  # legacy
 DEBUG = os.environ.get("_VIRTUALENV_DEBUG", None) == "1"
 if sys.version_info < (2, 7):
@@ -2126,23 +2126,25 @@ def convert(s):
 # file activate.fish
 ACTIVATE_FISH = convert(
     """
-eJyFVm1v2zYQ/q5fcZUdyClqB93HAMOQNh5iIIkDxw0wbAPNSJTFQSI1klLrYj9+R8qSKFtp8yGG
-yOfe77njBLYZ15DynEFRaQOvDCrNEvzHxR52WlYqZvDKxRWNDa+pYYuU62wH779yk3EBFFQlhAXb
-c5hBZkx5fXVlv3TG8nwRywIuQTOtuRTvF8EEbiUIaawgcAMJVyw2+WERBGkl0IoUQF6pznh6ICU1
-GcwTCD9LUTNlNBp0htyFkaBlwawje7AiEFMBqE7uBf/OwgDwTzPjRI7KplTt6+7CCrUXPejPj387
-RCqVM4SHygBG62N+WSzmR9yItnDaf1xPOyWNS0wkzW+cSfCAgb3wsmCtvZUFF+55FlxyRrLQmLKx
-w39gFETXEUR/iejEZMLaOlt70fIbFqjmylQ0Z6KGQiYMqEhQu6mUsKZNxrCaqqA5hoVQKQomzCJy
-VicItImReeLfQk0Vp6850w7FUzAMm28uMG1kfX9LXlab7Zebe/J0s70LByme77+BPYXZMDvncpdD
-OQZniK4WP/Pij+3d+vFu/bAc8aW7O3Whu/ixH0PYD7z5ffV8R54264enLVm/LDeb1a3nzwSeUTvW
-nRWlOUAuYyzIzvUraavrMrWzRaN5Lr+60ilWyBqhMoWdA5dKooZdOwFaWY2e7xbDUHI4Vx94Hi0V
-1cxrn0if2Gg6SRupmHNGKr7ngua9Hd88eLJjgBgI9hnxUD+TYGcSo7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S7uwzrFPddcGrtrg81X
+rGxruUYbuk7zfzKtC6pHP73/GQg3VGFLW12Qo/Mc81TrrGwPygT9Nnm+T17G8+fJbFomKoxDCD+L
+8BqbAobcwPtatir7cPO11D5oV+w8lutalnJNLys6l2wEj71Ty1DoBrvCfie9vy/uZ9P72eM4DM78
+qM9OvakPXvejDXvFG5fzp/ns8WmRzDD388nd2C/6M2rHhqbbnTkAlyl22tINYlK1rUv30nYj4Vx+
+cT2p6FbuESrXsHTgnZKoYVlRWyWr0fNl3A6Fw7n6wPNorIim3lxE+sRGOSLaSEWdM1KxDROEN3Z8
+8+DJdgFSSHCAEg/1PQl6JtFZq67Mt6t1RFdFHU9f2lUMHaXgaITw5heIhBQZflaFJREatYrI18Pq
+7E23z7tDJtPuo4aXLoTrXxgXIP5s1lG6SHvwSdhImVKU0z3xGSoOPE5sxxcE1bB4+YEwSbzXJAmt
+/v+PuP4jYVWennEFklbrsu2XPFXz02VBh3QJbHFX2PfCHyXJh8k0md4+jjETR5E638t+wxJL21P4
+MQ7KJwz/hhMO6XbF46kuPPW1tC+7pt92B5Pjh+G2/HZcEhy65qtv7ciSu8nz7YeH8XF+wuN991Hu
+Dm7k0wKbCRupTQy1bYKUcTqjRxpqTb4/9Gcz3YJ3cgIOHtnTlkN9bYgp9Du33XgyGlHErmN6x8kB
+N7MzUrTmS+FKiU+KT6WTEhcUxXBNQK17fGa/epjJ2m5+7+Avu2vuFN1hip1z/nIgyJY2tv37opms
+I2klzT3hyqiYMGuIrvSVjjrhMMBYklRyjL3cWl65kht1gyt9DVGHMAxweKj1uN0doae24tIyBfOO
+a6FOZy1jZzukdvvqN1kPccDLjbwGdtJ8m72rgeki+xOnXcf/CzFcuJM=
 """
 )
 


Test patch:
diff --git a/tests/activation/test_activation.py b/tests/activation/test_activation.py
--- a/tests/activation/test_activation.py
+++ b/tests/activation/test_activation.py
@@ -116,7 +116,10 @@ def __call__(self, monkeypatch):
         env = get_env()
         env.update(self.env)
 
-        raw = subprocess.check_output(invoke_shell, universal_newlines=True, stderr=subprocess.STDOUT, env=env)
+        try:
+            raw = subprocess.check_output(invoke_shell, universal_newlines=True, stderr=subprocess.STDOUT, env=env)
+        except subprocess.CalledProcessError as exception:
+            assert not exception.returncode, exception.output
         out = re.sub(r"pydev debugger: process \d+ is connecting\n\n", "", raw, re.M).strip().split("\n")
 
         # pre-activation