Self-evolving Context Database for AI Agents. Unify Agent Memory, Knowledge RAG and Skills.
Python agent-contextagent-memoryagent-pluginsagentic-ragcontext-databasedsh-pluginknowledge-basememorymemory-managementself-evolvingvector-database
feat(encryption): add encrypt unit test for plaintext shorter than the magic header (#1217)
baojun-zhang821287dcec74
diff --git a/openviking/utils/summarizer.py b/openviking/utils/summarizer.pyindex 41d2c4664..4e6129668 100644--- a/openviking/utils/summarizer.py+++ b/openviking/utils/summarizer.py@@ -56,7 +56,7 @@ class Summarizer:enqueued_count = 0telemetry = get_current_telemetry()- for uri, temp_uri in zip(resource_uris, temp_uris, strict=True):+ for uri, temp_uri in zip(resource_uris, temp_uris, strict=False):# Determine context_type based on URIcontext_type = get_context_type_for_uri(uri)diff --git a/tests/unit/crypto/test_encryptor.py b/tests/unit/crypto/test_encryptor.pyindex a4f4a61f5..b37b27cc6 100644--- a/tests/unit/crypto/test_encryptor.py+++ b/tests/unit/crypto/test_encryptor.py@@ -60,6 +60,16 @@ async def test_decrypt_unencrypted_data(encryptor):assert decrypted == plaintext[email protected]("plaintext", [b"", b"a", b"ab", b"abc"])+async def test_decrypt_unencrypted_short_plaintext(encryptor, plaintext):+ """Test decrypting unencrypted plaintext shorter than the magic header."""+ account_id = "test_account"++ decrypted = await encryptor.decrypt(account_id, plaintext)+ assert decrypted == plaintext++@pytest.mark.asyncioasync def test_decrypt_corrupted_ciphertext(encryptor):"""Test decrypting corrupted ciphertext."""