hazelcast / hazelcast/hazelcast-python-client

NearCacheTestCase.test_put_get

Open
#515 0 comments 0 reactions 0 assignees View on GitHub
Source: Internal Type: Test-Failure
Dominant language
Python
Stars
116
Forks
78
Avg merge
10d 22h
Merged PRs (30d)
1

Description

Failed on nightly tests with Python 3.8 on Windows

```
self =

def test_put_get(self):
near_cache = self.create_near_cache(
self.service, InMemoryFormat.OBJECT, 100, 100, EvictionPolicy.LRU, 100
)
for i in range(0, 120):
key = "key-{}".format(i)
value = "value-{}".format(i)
near_cache[key] = value
self.assertEqual(value, near_cache[key])
> self.assertEqual("value-0", near_cache["key-0"]) # prevent its eviction

tests\unit\near_cache_test.py:45:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
hazelcast\near_cache.py:161: in __getitem__
raise ke
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

self = NearCache(len=100, evicted=1), key = 'key-0'

def __getitem__(self, key):
try:
> value_record = super(NearCache, self).__getitem__(key)
E KeyError: 'key-0'

hazelcast\near_cache.py:155: KeyError
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.