closing db cursor
This commit is contained in:
		
							parent
							
								
									ba72802f1f
								
							
						
					
					
						commit
						707034153c
					
				| @ -256,6 +256,7 @@ def api_get_frames(): | |||||||
|     frames = [] |     frames = [] | ||||||
|     for ent in cur[:QUERY_LIMIT]: |     for ent in cur[:QUERY_LIMIT]: | ||||||
|         frames += frames_from_db_entry(ent)  # pre-process this step for prod TODO |         frames += frames_from_db_entry(ent)  # pre-process this step for prod TODO | ||||||
|  |     cur.close() | ||||||
| 
 | 
 | ||||||
|     # filter by relevant hw |     # filter by relevant hw | ||||||
|     frames = [x for x in frames if x.hw == hw] |     frames = [x for x in frames if x.hw == hw] | ||||||
| @ -308,6 +309,7 @@ def api_get_functor_frames(): | |||||||
|     frames = [] |     frames = [] | ||||||
|     for ent in cur[:QUERY_LIMIT]: |     for ent in cur[:QUERY_LIMIT]: | ||||||
|         frames += frames_from_db_entry(ent)  # pre-process this step for prod TODO |         frames += frames_from_db_entry(ent)  # pre-process this step for prod TODO | ||||||
|  |     cur.close() | ||||||
| 
 | 
 | ||||||
|     # filter by relevant functor |     # filter by relevant functor | ||||||
|     frames = [x for x in frames if functor in x.get_functors()] |     frames = [x for x in frames if functor in x.get_functors()] | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user