Registry / serialization / xmind
library1.2.0pypypi✓ verified 85d ago

XMind is a Python library for creating, parsing, and updating XMind mind map files. It supports XMind workbooks with topics, sheets, and relationships. Current version is 1.2.0, with an irregular release cadence. Requires Python 3.0 to 3.11 (not 3.12+). Note: This library is not actively maintained on PyPI; some features may be incomplete or buggy.

pip install xmind
INSTALL
IMPORT
SIG · XMIND
X
xmind
serializationpythonv1.2.0
Install
1.5s avg
Import
104ms
Disk
16MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v1.2.0 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 0.110s · 18MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 1.5s · import 0.098s · 19MB
16MB installed
● package 16MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

xmind
import xmind
The library exports a single module 'xmind'. No subpackage imports needed.

Create a new XMind workbook, add a root topic, save to file, then reload and print the topic.

import xmind # Create a new workbook workbook = xmind.Workbook() sheet = workbook.getPrimarySheet() topic = sheet.getRootTopic() topic.setTitle("Main Topic") # Save to file workbook.save("test.xmind") print("Saved as test.xmind") # Load an existing workbook loaded = xmind.Workbook("test.xmind") loaded_sheet = loaded.getPrimarySheet() loaded_topic = loaded_sheet.getRootTopic() print("Root topic:", loaded_topic.getTitle())
Debug
Known issues
gotchaThe library does not support Python 3.12+ due to setup.py restrictions. Use Python 3.10 or 3.11.
fix
Use Python 3.10 or 3.11, or fork and fix the setup.py to support newer Python.
affects: >=1.0.0
gotchaThe Workbook constructor can either take a file path to load an existing file or no argument to create a new one. However, calling it with a path that does not exist will raise a FileNotFoundError, not create a new file.
fix
Check if file exists before loading: 'from pathlib import Path; if Path('test.xmind').exists(): wb = xmind.Workbook('test.xmind'); else: wb = xmind.Workbook()'
affects: >=1.0.0
deprecatedThe method 'setTitle' is used instead of 'set_title' in some examples. There is no official 'set_title' method.
fix
Use 'topic.setTitle("...")' not 'topic.set_title(...)'.
affects: >=1.0.0
gotchaSaving a workbook may not work correctly if the directory does not exist. The library does not create directories automatically.
fix
Ensure the directory exists before calling 'save'.
affects: >=1.0.0
Errors
Common errors & fixes
ModuleNotFoundError: No module named 'xmind'
Library not installed or installed in wrong environment.
fix
Run 'pip install xmind' in your active Python environment.
FileNotFoundError: [Errno 2] No such file or directory: 'test.xmind'
Attempting to open a non-existent file with the Workbook constructor.
fix
Do not pass a path to Workbook if you intend to create a new file. Use 'workbook = xmind.Workbook()' for new files.
AttributeError: 'NoneType' object has no attribute 'getTitle'
Calling getTitle on a topic that is None. This can happen if the sheet has no root topic or if the path is incorrect.
fix
Ensure the workbook has a sheet with a root topic. Always check for None: 'if topic: print(topic.getTitle())'
Upgrade
Version history
1.2.0latest on PyPI · released Jan 10, 2019
Audit
Dependencies

No dependency data recorded yet.

Agent activity
111 hits · last 30 days
node
102
Amazon
1
OpenAI (training)
1
Resources
xmind — pip install xmind · libregistry