Release v0.10.1 - Bug Fix: Nested Page Pulling
Release Date: July 2, 2025
Type: Bug Fix Release
🐛 Critical Bug Fix
Fixed: Pull Command Not Fetching Nested Sub-Pages
Issue: The pull command was failing to fetch nested sub-pages from Notion workspaces, only retrieving direct children of the parent page.
Root Cause: An infinite loop bug in the buildFilePathForPage function's safety check logic was causing timeouts during recursive page fetching.
Solution:
- Fixed infinite loop by implementing proper cycle detection using a
visitedmap - Enhanced error handling with warnings for missing parent pages and cycle detection
- Improved recursive logic for parent traversal in nested page hierarchies
Impact:
- ✅ Successfully pulls deeply nested page structures (e.g., Page → Sub Page 1 → Sub Page 2)
- ✅ Creates proper nested directory structure mirroring Notion hierarchy
- ✅ Eliminates timeout issues during pull operations
- ✅ Maintains correct frontmatter with notion_id, timestamps, and titles for all pages
📁 Directory Structure Support
The pull command now correctly creates nested directories that mirror your Notion page hierarchy:
docs/
├── Main Document.md
├── Main Document/
│ ├── Sub Page 1.md
│ └── Sub Page 1/
│ └── Sub Page 2.md
└── Another Document/
└── Nested Page.md
🔧 Technical Details
Files Modified:
pkg/sync/engine.go- FixedbuildFilePathForPagefunction with proper cycle detection- Added comprehensive safety checks to prevent infinite loops
- Enhanced logging for debugging nested page issues
Testing:
- Verified with multiple nested page structures
- Tested with 3 main pages each containing 2 levels of sub-pages (9 total pages)
- Confirmed proper file path construction and directory creation
📋 What's Included
This release focuses exclusively on the critical bug fix for nested page pulling. All other functionality remains unchanged from v0.10.0.
Previous Features (v0.10.0):
- Extended Notion block support (images, callouts, toggles, bookmarks, dividers)
- CSV/Database integration with full import/export capabilities
- Enhanced markdown features (LaTeX math equations, Mermaid diagrams)
- Advanced conflict resolution system
🚀 Upgrade Instructions
-
Update to v0.10.1:
# Download latest release curl -L https://github.com/byvfx/go-notion-md-sync/releases/download/v0.10.1/notion-md-sync-linux-amd64.tar.gz | tar xz
-
Test nested page pulling:
notion-md-sync pull
-
Verify nested directory structure:
Check that sub-pages are properly organized in subdirectories matching your Notion hierarchy.
💡 Next Steps
- Consider organizing your Notion workspace with clear hierarchies to take advantage of nested directory support
- Use the pull command to maintain local copies of complex document structures
- Report any issues with deeply nested page structures on GitHub
🙏 Community
This bug was identified and resolved based on user feedback. Thank you for helping improve notion-md-sync!
For questions or issues, please visit: https://github.com/byvfx/go-notion-md-sync/issues