]> granicus.if.org Git - python/commitdiff
Fix typo in example (pointed out by a couple of people, most recently Ken Rimey)
authorNick Coghlan <ncoghlan@gmail.com>
Sat, 20 Oct 2012 10:13:21 +0000 (20:13 +1000)
committerNick Coghlan <ncoghlan@gmail.com>
Sat, 20 Oct 2012 10:13:21 +0000 (20:13 +1000)
Doc/library/concurrent.futures.rst

index 62d8eac69ec80a6864f75b454bfde2bcb69ba26f..7ed99d56192e90b3c04a0a960924f7c0eaa5676c 100644 (file)
@@ -146,7 +146,7 @@ ThreadPoolExecutor Example
        # Start the load operations and mark each future with its URL
        future_to_url = {executor.submit(load_url, url, 60):url for url in URLS}
        for future in concurrent.futures.as_completed(future_to_url):
-           url = future_to_url[url]
+           url = future_to_url[future]
            try:
                data = future.result()
            except Exception as exc: