daily pastebin goal
31%
SHARE
TWEET

Untitled

a guest Jan 20th, 2019 56 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ["id", "name", "wkt", "created", "radius", "round"]
  2.    
  3. {"id":"1", "name":"a", "round":5}  
  4. {"id":"2", "wkt": "POINT(1.1)", "created":"2018-22-11T10:00:00"}  
  5. {"id":"3", "radius":3}
  6.    
  7. for line in lines:
  8.     line_dict = json.loads(line)
  9.     for key in keys:
  10.         if not key in line_dict:
  11.             line_dict[key] = None
  12.     yield line_dict
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top