"tests/vscode:/vscode.git/clone" did not exist on "3fd2e635d8f1eee0aff11613517c2c97a623c7d4"
Unverified Commit fcc0f5ed authored by Liangsheng Yin's avatar Liangsheng Yin Committed by GitHub
Browse files

Fix wrong assert (#1028)

parent a97df791
......@@ -39,10 +39,12 @@ class ChunkCache(BasePrefixCache):
kv_indices = self.req_to_token_pool.req_to_token[
req.req_pool_idx, : len(token_ids)
]
assert req.rid in self.entries
self.req_to_token_pool.free(req.req_pool_idx)
self.token_to_kv_pool.free(kv_indices)
if req.rid in self.entries:
del self.entries[req.rid]
def cache_unfinished_req(self, req: "Req", token_ids=None):
if token_ids is None:
token_ids = req.fill_ids
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment