Ticket #1233: zetuptoolz-debugprints.diff.patch

File zetuptoolz-debugprints.diff.patch, 4.6 KB (added by zooko, at 2010-11-03T20:48:26Z)
  • setuptools-0.6c16dev2.egg/pkg_resources.py

    Copying pristine 50 done, 16 queued. __init__.py
    Copying pristine 76 done, 26 queued. helper.rst
    Copying pristine 126 done, 17 queued. Makefile
    Copying pristine 221 done, 26 queued. tahoe_disktotal
    Copying pristine 278 done, 22 queued. install_egg_info.py
    Copying pristine 343 done, 31 queued. checker.py
    Copying pristine 372 done, 23 queued. common.py
    Copying pristine 400 done, 19 queued. tahoe_get.py
    Copying pristine 422 done, 56 queued. bench_dirnode.py
    Copying pristine 446 done, 32 queued. test_hashtree.py
    Copying pristine 483 done, 27 queued. encodingutil.py
    Copying pristine 511 done, 36 queued. common.py
    Copying pristine 533 done, 14 queued. root.py
    Copying pristine 548 done, 2 queued. registry.py
    Reading pristine 69 done, 471 queued. accfe419cf8e0316dabc02f7c660bcca6127a3c061
    diff -rN -u old-trunk/setuptools-0.6c16dev2.egg/pkg_resources.py new-trunk/setuptools-0.6c16dev2.egg/pkg_resources.py
    old new  
    808808        """
    809809        dist = working_set.find(req)
    810810        if dist is not None:
     811            print "yyy 0 ", req, dist
    811812            return dist
    812813
    813814        # first try to find a platform-dependent dist
    814815        for dist in self[req.key]:
     816            print "yyy 1 ", req, dist
    815817            if dist in req and dist.platform is not None:
     818                print "yyy 2 ", req, dist
    816819                return dist
    817820
    818821        # then try any other dist
    819822        for dist in self[req.key]:
     823            print "yyy 3 ", req, dist
    820824            if dist in req:
     825                print "yyy 4 ", req, dist
    821826                return dist
    822827
     828        print "yyy 5 ", req, dist
    823829        return self.obtain(req, installer) # try and download/install
    824830
    825831    def obtain(self, requirement, installer=None):
     
    26252631else:
    26262632    # Yes: ensure the requirements are met, by prefixing sys.path if necessary
    26272633    try:
    2628         working_set.require(__requires__)
     2634        if __requires__:
     2635            working_set.require(__requires__)
    26292636    except (VersionConflict, DistributionNotFound):     # try it without defaults already on sys.path
    26302637        working_set = WorkingSet([])    # by starting with an empty path
    26312638        try:
  • setuptools-0.6c16dev2.egg/setuptools/package_index.py

    diff -rN -u old-trunk/setuptools-0.6c16dev2.egg/setuptools/package_index.py new-trunk/setuptools-0.6c16dev2.egg/setuptools/package_index.py
    old new  
    216216
    217217        dists = distros_for_filename(fn)
    218218        if dists:
    219             self.debug("Found: %s", fn)
     219            self.debug("Found: %s zzz 0 %s(%s)", fn, self.add, dists)
    220220            map(self.add, dists)
    221221
    222222    def url_ok(self, url, fatal=False):
     
    437437            # Find a matching distribution; may be called more than once
    438438
    439439            for dist in env[req.key]:
     440                print "aaa 0", dist
    440441
    441442                if dist.precedence==DEVELOP_DIST and not develop_ok:
     443                    print "aaa 1 ", dist
    442444                    if dist not in skipped:
     445                        print "aaa 2", dist
    443446                        self.warn("Skipping development or system egg: %s",dist)
    444447                        skipped[dist] = 1
    445448                    continue
    446449
    447450                if dist in req and (dist.precedence<=SOURCE_DIST or not source):
     451                    print "aaa 3", dist
    448452                    return dist
    449453
    450454
    451455
    452456        if force_scan:
     457            print "aaa 4", dist
    453458            self.prescan()
    454459            self.find_packages(requirement)
    455460            dist = find(self, requirement)
    456461           
    457462        if local_index is not None:
     463            print "aaa 5", dist
    458464            dist = dist or find(local_index, requirement)
    459465
    460466        if dist is None and self.to_scan is not None:
     467            print "aaa 6", dist
    461468            self.prescan()
    462469            dist = find(self, requirement)
    463470
    464471        if dist is None and not force_scan:
     472            print "aaa 7", dist
    465473            self.find_packages(requirement)
    466474            dist = find(self, requirement)
    467475
    468476        if dist is None:
     477            print "aaa 8", dist
    469478            self.warn(
    470479                "No local packages or download links found for %s%s",
    471480                (source and "a source distribution of " or ""),
    472481                requirement,
    473482            )
    474483        else:
     484            print "aaa 9", dist
    475485            self.info("Best match: %s", dist)
    476486            return dist.clone(location=self.download(dist.location, tmpdir))
    477487