Skip to content

Commit 537927f

Browse files
authored
Merge pull request pandas-dev#167 from manahl/chunkstore-write-fix
Chunkstore fix for removing SHAs Issue pandas-dev#166
2 parents f8d3839 + 64501f0 commit 537927f

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

CHANGES.md

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
* Bugfix: TickStore.read now respects `allow_secondary=True`
77
* Bugfix: #147 Add get_info method to ChunkStore
88
* Bugfix: Periodically re-cache the library.quota to pick up any changes
9+
* Bugfix: #166 Add index on SHA for ChunkStore
910

1011
### 1.25 (2016-05-23)
1112

arctic/chunkstore/chunkstore.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,7 @@ def write(self, symbol, item, chunk_size):
219219
doc['append_count'] = 0
220220

221221
if previous_shas:
222-
mongo_retry(self._collection.delete_many)({'sha': {'$in': list(previous_shas)}})
222+
mongo_retry(self._collection.delete_many)({'symbol': symbol, 'sha': {'$in': list(previous_shas)}})
223223

224224
mongo_retry(self._symbols.update_one)({'symbol': symbol},
225225
{'$set': doc},

0 commit comments

Comments
 (0)