Skip to main content
Glama

DollhouseMCP

by DollhouseMCP
SESSION_NOTES_2025-09-29-RELEASE-V1912.md10.3 kB
# Session Notes: Release v1.9.12 - Memory System Critical Fixes **Date:** September 29, 2025 (Afternoon) **Duration:** ~3 hours **Participants:** Mick, Claude Code (Alex Sterling + Sonar Guardian personas) ## Session Overview Successfully diagnosed, fixed, and released critical memory system bugs affecting metadata preservation and test isolation. Completed full release cycle from bug fix through production deployment. ## What We Accomplished ### 1. Fixed Critical Memory System Bugs **Issue #1196: Memory Metadata Preservation** - **Problem**: PortfolioIndexManager was overwriting memory metadata with generic "Memory element" text - **Root Cause**: Used SecureYamlParser (designed for Markdown frontmatter) on pure YAML memory files - **Solution**: - Switched to `yaml.load()` with FAILSAFE_SCHEMA for pure YAML files - Added proper metadata merging for mixed structures (top-level + nested) - Added security validation (size limits, type checking) - **Result**: Memory descriptions now preserved correctly - **PR**: #1197 **Issue #1194: Test Isolation** - **Problem**: Tests were finding 112+ real user memories instead of 3 test memories - **Root Cause**: Singleton pattern persisted across tests, environment variables set too late - **Solution**: - Set `DOLLHOUSE_PORTFOLIO_DIR` before singleton instantiation - Reset singleton instances in beforeAll/afterAll - Fixed memory YAML structure in test data - **Result**: Tests properly isolated, reproducible - **PR**: #1195 **SonarCloud Issues Fixed (PR #1195)** - S7781: Use `String#replaceAll()` instead of `replace(/pattern/g)` - S1135 (x2): Removed TODO comments, documented test patterns **Security Review Addressed (PR #1197)** - Added content size validation (1MB limit) - Added type safety validation for yaml.load() return values - Added security audit suppression with full documentation ### 2. Closed Verified Issues - #659 - Tool execution timeout (fixed in PR #662, verified) - #404 - Element system MCP exposure (fixed in PR #405, verified) - #919 - Duplicate tool names (fixed in PR #920, verified) ### 3. Completed Full Release Cycle **Documentation Updates:** - Updated CHANGELOG.md for v1.9.12 - Built all README variants (GitHub, NPM) - Created comprehensive release notes **Release Process:** 1. Created release branch `release/v1.9.12` from develop 2. Bumped version: 1.9.11 → 1.9.12 in package.json 3. Created release PR #1201 to main 4. Merged to main (all CI checks passing) 5. Tagged release: `v1.9.12` 6. Published GitHub release 7. Merged back to develop ## Test Results **Before Fixes:** - Memory portfolio index tests: 3/8 passing - Descriptions: "Memory element" (incorrect) - Search/triggers broken **After Fixes:** - Memory portfolio index tests: 8/8 passing ✅ - Descriptions: Preserved correctly ✅ - Search/triggers working ✅ - Total: 2260/2366 tests passing - 9 failures: Pre-existing GitHubRateLimiter test infrastructure issues (deferred) - 1 failure: Extended Node Compatibility (deferred) ## Key Technical Decisions ### Why yaml.load() Instead of SecureYamlParser? **Context**: Memory files are pure YAML, not Markdown with YAML frontmatter - SecureYamlParser expects: `---\nYAML\n---\nContent` - Memory files contain: Pure YAML with no frontmatter markers - Result: `parsed.data = {}`, metadata used fallback defaults **Solution**: Use `yaml.load()` with security measures: - FAILSAFE_SCHEMA (prevents code execution) - Size validation (1MB limit) - Type checking (reject null/primitives/arrays) - Same approach as MemoryManager and ConfigManager ### Why Defer Test Failures? **GitHubRateLimiter (9 tests)**: Test infrastructure issue, not runtime bug. Complex async/timing issues that need dedicated session. **Extended Node Compatibility**: Failing on develop but not blocking memory fixes. Can investigate post-release. **Decision**: Ship critical memory fixes now, address test infrastructure asynchronously. ## Pull Requests Merged 1. **PR #1195** - Test isolation + SonarCloud fixes 2. **PR #1197** - Memory metadata preservation + security 3. **PR #1198** - CHANGELOG update 4. **PR #1201** - Release v1.9.12 to main ## Files Modified ### Core Fixes: - `src/portfolio/PortfolioIndexManager.ts` - Fixed YAML parsing for memories - `src/security/audit/config/suppressions.ts` - Added security suppression - `test/integration/memory-portfolio-index.test.ts` - Fixed test isolation ### Release Files: - `package.json` - Version bump to 1.9.12 - `CHANGELOG.md` - Added v1.9.12 entry - `README.md`, `README.github.md`, `README.npm.md` - Rebuilt with changes - `security-audit-report.md` - Updated from CI runs ## 🚨 NEXT STEPS - DO NOT FORGET ### 1. NPM Publishing (IF NOT AUTO-PUBLISHED) **Check if auto-published:** ```bash npm view @dollhousemcp/mcp-server version # Should show 1.9.12 if auto-published # If shows 1.9.11, manual publish needed ``` **Manual publish process (if needed):** ```bash # 1. Ensure on main branch with v1.9.12 tag git checkout main git pull git describe --tags # Should show v1.9.12 # 2. Ensure built artifacts exist npm run build ls -la dist/ # Should have compiled JS files # 3. Login to NPM (if not already) npm login # 4. Publish to NPM npm publish --access public # 5. Verify published npm view @dollhousemcp/mcp-server version npm view @dollhousemcp/mcp-server dist-tags ``` **Publish checklist:** - [ ] Verify version 1.9.12 shows on NPM - [ ] Test installation: `npm install @dollhousemcp/mcp-server@1.9.12` - [ ] Verify package.json metadata correct on NPM page - [ ] Check README renders correctly on NPM ### 2. Release Announcement **Channels to announce:** **GitHub:** - Already done: https://github.com/DollhouseMCP/mcp-server/releases/tag/v1.9.12 **Discord/Community (if exists):** ```markdown 🚀 **DollhouseMCP v1.9.12 Released!** Critical memory system fixes: ✅ Memory metadata now preserved correctly ✅ Fixed test isolation issues ✅ Added security validation ✅ 8/8 memory tests passing Install: `npm install @dollhousemcp/mcp-server@1.9.12` Release notes: https://github.com/DollhouseMCP/mcp-server/releases/tag/v1.9.12 ``` **Social Media (if applicable):** - Twitter/X, LinkedIn, Reddit (r/ClaudeAI, r/LocalLLaMA) - Focus: "Critical bug fix for memory persistence" **NPM Package Page:** - Automatically updated when published ### 3. Documentation Sites Update **What needs updating:** **Website (if exists at dollhousemcp.com or similar):** - [ ] Update version number references from 1.9.11 to 1.9.12 - [ ] Update installation instructions (if hardcoded) - [ ] Add release announcement/news post - [ ] Update changelog page **Location check:** ```bash # Check if website repo exists cd ~/Developer/Organizations/DollhouseMCP ls -la | grep website # OR gh repo list DollhouseMCP | grep website ``` **If website exists:** ```bash cd website/ # or docs/ or site/ # Find version references grep -r "1.9.11" . # Update package.json if it installs mcp-server as example # Update docs/installation.md or similar # Rebuild and deploy ``` **GitHub Pages (if using):** - May auto-update from README.md changes - Check: https://dollhousemcp.github.io/mcp-server/ **Documentation that auto-updates:** - ✅ README.md on GitHub (already updated) - ✅ NPM package page (updates on publish) - ✅ GitHub release notes (already created) ## Commands Reference ### Check Current State ```bash # Check NPM version npm view @dollhousemcp/mcp-server version # Check local version cat package.json | grep version # Check git tags git tag -l "v1.9.*" # Check release exists gh release view v1.9.12 ``` ### Verify Release ```bash # Test installation npm install -g @dollhousemcp/mcp-server@1.9.12 # Check installed version dollhouse --version # or mcp-server --version # Verify functionality dollhouse list_elements --type memories ``` ## Lessons Learned ### What Went Well 1. **Systematic debugging**: Used test isolation to reveal real bugs 2. **Security-first approach**: Added validation even when not required 3. **Clean git workflow**: GitFlow Guardian enforced best practices 4. **Comprehensive testing**: 8/8 tests passing proves fixes work ### What Could Be Improved 1. **Earlier singleton reset**: Could have caught test isolation issue sooner 2. **Parser documentation**: SecureYamlParser name implies general use, but it's Markdown-specific 3. **Test coverage warnings**: Should have noticed 3/8 passing earlier ### Technical Debt Identified 1. GitHubRateLimiter test failures (9 tests) - needs dedicated session 2. Extended Node Compatibility check failing - investigate cause 3. Consider adding resetInstance() methods to singletons (but acceptable pattern for tests) ## Related Issues & PRs **Issues Closed This Session:** - #1196 - Memory metadata preservation - #1194 - Test isolation - #659 - Tool execution timeout (verification) - #404 - Element system MCP exposure (verification) - #919 - Duplicate tool names (verification) **PRs Merged:** - #1195 - Test isolation + SonarCloud fixes - #1197 - Memory metadata preservation - #1198 - CHANGELOG update - #1201 - Release v1.9.12 **Related Issues (deferred):** - GitHubRateLimiter test failures (no issue filed yet) - Extended Node Compatibility failure (no issue filed yet) ## Context for Next Session **Current State:** - Version 1.9.12 released to production - All memory fixes deployed - Develop branch synchronized with main **If Continuing Work:** 1. **Check NPM publish status first** - critical to verify 2. **Announce release** - inform users of critical fix 3. **Consider** creating issues for deferred test failures if needed 4. **Monitor** for any user reports of memory issues **Branch State:** - `main`: v1.9.12 (production) - `develop`: v1.9.12 (synchronized) - All feature branches deleted after merge ## Metrics **Time Investment:** - Bug diagnosis and fix: ~1.5 hours - Security review and updates: ~30 minutes - Release process: ~1 hour - Total: ~3 hours **Code Changes:** - Files modified: 27 - Lines added: 3,295 - Lines removed: 93 - Net change: +3,202 lines **Quality Improvements:** - SonarCloud issues fixed: 3 - Security validations added: 3 - Test coverage improved: 3/8 → 8/8 (166% improvement) - Critical bugs fixed: 2 --- **Session completed successfully. Release v1.9.12 is live!** 🚀

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/DollhouseMCP/DollhouseMCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server