Commits

Anonymous committed 2231487

Fix local --find-links eggs not being copied except with --always-copy.
(merge from trunk)

Comments (0)

Files changed (2)

 Release Notes/Change History
 ============================
 
+0.6b3
+ * Fix local --find-links eggs not being copied except with --always-copy.
+
 0.6b2
  * Don't install or update a ``site.py`` patch when installing to a
    ``PYTHONPATH`` directory with ``--multi-version``, unless an

setuptools/command/easy_install.py

     def install_item(self, spec, download, tmpdir, deps, install_needed=False):
 
         # Installation is also needed if file in tmpdir or is not an egg
+        install_needed = install_needed or self.always_copy
         install_needed = install_needed or os.path.dirname(download) == tmpdir
         install_needed = install_needed or not download.endswith('.egg')
 
+        if spec and not install_needed:
+            # at this point, we know it's a local .egg, we just don't know if
+            # it's already installed.
+            for dist in self.local_index[spec.project_name]:
+                if dist.location==download:
+                    break
+            else:
+                install_needed = True   # it's not in the local index
+
         log.info("Processing %s", os.path.basename(download))
 
-        if install_needed or self.always_copy:
+        if install_needed:
             dists = self.install_eggs(spec, download, tmpdir)
             for dist in dists:
                 self.process_distribution(spec, dist, deps)
 
 
 
-
-
-
-
-
-
-
-
-
-
     def process_distribution(self, requirement, dist, deps=True, *info):
         self.update_pth(dist)
         self.package_index.add(dist)
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.