Fix loading large data with missing chunks from the cache.

Review Request #7272 — Created May 1, 2015 and submitted

Information

Djblets
release-0.9.x
ad3becf...

Reviewers

The cache support was recently overhauled to support generators, but
this caused the MissingChunkError to be propagated to the code iterating
through results, rather than the code initially fetching the data from
cache.

To fix this, I've split the function into two: One that does the initial
fetching and missing chunk detection, and one that iterates through
results.

A unit test was added that failed with a propagated MissingChunkError
before this fix, and succeeded in falling through to the cache data
generation function after the fix.

The new unit test failed before, and passed after. Also tested manually.

Description From Last Updated

Should be "Fetch large data"

daviddavid

Iterate.

daviddavid

undefined name 'key'

reviewbotreviewbot
reviewbot
  1. Tool: Pyflakes
    Processed Files:
        djblets/cache/tests.py
        djblets/cache/backend.py
    
    
    
    Tool: PEP8 Style Checker
    Processed Files:
        djblets/cache/tests.py
        djblets/cache/backend.py
    
    
  2. djblets/cache/backend.py (Diff revision 1)
     
     
    Show all issues
     undefined name 'key'
    
  3. 
      
david
  1. 
      
  2. djblets/cache/backend.py (Diff revision 1)
     
     
    Show all issues

    Should be "Fetch large data"

  3. djblets/cache/backend.py (Diff revision 1)
     
     
    Show all issues

    Iterate.

  4. 
      
chipx86
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-0.9.x (4b67f2b)
Loading...