Ubuntu Pastebin

Paste from cjwatson at Tue, 11 Oct 2016 11:06:13 +0000

Download as text
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
diff --git a/snapcraft/plugins/python.py b/snapcraft/plugins/python.py
index dbb4214..a2179fa 100644
--- a/snapcraft/plugins/python.py
+++ b/snapcraft/plugins/python.py
@@ -206,23 +206,23 @@ class PythonPlugin(snapcraft.BasePlugin):
                                             self.options.requirements)
             if download:
                 pip.download(['--requirement', requirements])
-            else:
                 pip.wheel(['--requirement', requirements])
+            else:
                 pip.install(['--requirement', requirements])
 
         if self.options.python_packages:
             if download:
                 pip.download(self.options.python_packages)
-            else:
                 pip.wheel(self.options.python_packages)
+            else:
                 pip.install(self.options.python_packages)
 
         if os.path.exists(setup):
             cwd = os.path.dirname(setup)
             if download:
                 pip.download(['.'], cwd=cwd)
-            else:
                 pip.wheel(['.'], cwd=cwd)
+            else:
                 pip.install(['.'], cwd=cwd)
 
     def _fix_permissions(self):
Download as text