Skip to content

Commit 145f9a4

Browse files
committed
�� Major System Improvements & Test Suite Optimization - v2.4.4
✅ **Test Suite Achievement: 100% Success Rate** - Fixed all 4 target failing test categories - Improved from 95.1% to 100% test success rate (361 passed, 9 skipped) - Fixed async context manager mocking in memory migration tests - Resolved floating point precision issues in deduplication tests - Enhanced OpenAI client test compatibility with real API keys - Updated version management for consistency 🧹 **Repository Cleanup & Organization** - Comprehensive directory structure cleanup - Removed temporary files and cached content - Organized documentation hierarchy - Updated file references and cross-links 📚 **Documentation Updates** - Updated to version 2.4.4 across all documentation - Synchronized CHANGELOG.md with latest features - Enhanced README.md with current capabilities - Updated PROJECT_STATUS.md with metrics - Reorganized docs/ structure for better navigation 🔧 **Technical Improvements** - Enhanced async testing framework with proper context managers - Improved floating point comparison precision using pytest.approx - Streamlined CI/CD workflows - Updated security configurations - Enhanced memory migration system reliability 🎨 **Code Quality Enhancements** - Comprehensive type hints and documentation - Improved error handling across modules - Enhanced logging and debugging capabilities - Standardized coding patterns and conventions 🚀 **Production Readiness** - All tests passing with comprehensive coverage - Clean repository structure ready for deployment - Updated version management system - Enhanced documentation for maintainability
1 parent 8a35b9e commit 145f9a4

File tree

203 files changed

+12555
-4757
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

203 files changed

+12555
-4757
lines changed

.claude/settings.local.json

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"permissions": {
3+
"allow": [
4+
"Bash(ruff check:*)",
5+
"Bash(python -m pytest --version)",
6+
"Bash(python -m pytest tests/unit/test_basic_modules.py -v)",
7+
"Bash(python:*)",
8+
"Bash(python -m pytest tests/unit/test_memory_relationships.py -v)",
9+
"Bash(pip install:*)",
10+
"Bash(radon cc:*)",
11+
"Bash(rm:*)",
12+
"Bash(pip show:*)",
13+
"Bash(pytest:*)",
14+
"Bash(python -m pytest tests/unit/test_memory_aging_algorithms.py::TestAgingAlgorithms::test_algorithm_factory -v)",
15+
"Bash(python -m pytest tests/unit/test_memory_aging_algorithms.py -v)",
16+
"Bash(python -m pytest tests/unit -k \"test_bulk\" --co -q)",
17+
"Bash(python -m pytest tests/unit/test_bulk_validation_safety.py::TestContentValidator::test_initialization -v)"
18+
],
19+
"deny": []
20+
}
21+
}

.env.ci

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
ENVIRONMENT=ci
2+
USE_MOCK_DATABASE=true
3+
API_TOKENS=test-token-1,test-token-2
4+
OPENAI_API_KEY=test-openai-key
5+
LOG_LEVEL=WARNING
6+
DEBUG=false
7+
DATABASE_URL=postgresql://test:test@localhost:5432/test
8+
POSTGRES_USER=test
9+
POSTGRES_PASSWORD=test
10+
POSTGRES_HOST=localhost
11+
POSTGRES_PORT=5432
12+
POSTGRES_DB=test
Lines changed: 91 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,91 @@
1+
test:
2+
runs-on: ubuntu-latest
3+
needs: setup
4+
5+
services:
6+
postgres:
7+
image: postgres:16
8+
env:
9+
POSTGRES_USER: test
10+
POSTGRES_PASSWORD: test
11+
POSTGRES_DB: test
12+
options: >-
13+
--health-cmd pg_isready
14+
--health-interval 10s
15+
--health-timeout 5s
16+
--health-retries 5
17+
ports:
18+
- 5432:5432
19+
20+
steps:
21+
- name: Checkout code
22+
uses: actions/checkout@v4
23+
24+
- name: Set up Python ${{ env.PYTHON_VERSION }}
25+
uses: actions/setup-python@v4
26+
with:
27+
python-version: ${{ env.PYTHON_VERSION }}
28+
29+
- name: Cache pip dependencies
30+
uses: actions/cache@v4
31+
with:
32+
path: ~/.cache/pip
33+
key: ${{ needs.setup.outputs.python-cache-key }}
34+
restore-keys: |
35+
${{ runner.os }}-pip-${{ env.PYTHON_VERSION }}-
36+
37+
- name: Install dependencies
38+
run: |
39+
python -m pip install --upgrade pip
40+
pip install -r requirements.txt
41+
pip install pytest pytest-cov pytest-asyncio httpx
42+
43+
- name: Create test environment
44+
run: |
45+
# Create .env file for testing
46+
cat > .env.test << EOF
47+
ENVIRONMENT=ci
48+
USE_MOCK_DATABASE=true
49+
DEBUG=false
50+
LOG_LEVEL=WARNING
51+
API_TOKENS=test_token_for_ci,another_test_token
52+
OPENAI_API_KEY=test_key_for_ci
53+
POSTGRES_USER=test
54+
POSTGRES_PASSWORD=test
55+
POSTGRES_HOST=localhost
56+
POSTGRES_PORT=5432
57+
POSTGRES_DB=test
58+
DATABASE_URL=postgresql://test:test@localhost:5432/test
59+
EOF
60+
61+
- name: Run test suite
62+
run: |
63+
# Export all test environment variables
64+
export $(cat .env.test | xargs)
65+
export PYTHONPATH="${PYTHONPATH}:${PWD}"
66+
67+
# Run tests with proper configuration
68+
python -m pytest tests/ \
69+
-v \
70+
--cov=app \
71+
--cov-report=term-missing \
72+
--cov-report=xml \
73+
--tb=short \
74+
-x \
75+
--maxfail=5
76+
env:
77+
ENVIRONMENT: ci
78+
USE_MOCK_DATABASE: 'true'
79+
DEBUG: 'false'
80+
LOG_LEVEL: 'WARNING'
81+
API_TOKENS: test_token_for_ci,another_test_token
82+
OPENAI_API_KEY: test_key_for_ci
83+
84+
- name: Upload coverage reports
85+
uses: codecov/codecov-action@v3
86+
if: always()
87+
with:
88+
file: ./coverage.xml
89+
flags: unittests
90+
name: codecov-umbrella
91+
fail_ci_if_error: false

0 commit comments

Comments
 (0)