v0.1.2 add file support for custom vocabulary
[0.1.2] - 2026-07-30
Added
--file / -fCLI option onste100-mcp(repeatable): pass one or more
*.jsonlvocabulary files at startup. Paths are merged with those from
STE100_MCP_FILES; duplicates are removed while preserving order.Factoryclass insettings.py— thread-safe singleton for
Settingsusing a double-checked lock. Class-level state removes the
need for a module-levelglobalvariable.Factory.create_instance(extra_files)— creates the singleton, merges
CLI-supplied paths with env-supplied paths, asserts it is called only once.Factory.get_instance()— returns the singleton, asserts
create_instancewas called first.
tests/settings/test_factory.py— 8 unit tests covering singleton
creation, identity, deduplication, and bothAssertionErrorguard paths.
Changed
cli.pycallsFactory.create_instance(files or [])beforemcp.run()
so CLI-supplied paths are available to the server lifespan.server.py_lifespancallsFactory.get_instance()instead of
constructing a newSettings()on every startup.
Fixed
- Removed bogus
--filevalidation block incli.pythat called
load_dotenvinstead of exiting on error (Typer'sexists=Truealready
rejects non-existent paths). - Changed
--filedefault from mutable[]toNoneto avoid the
mutable-default-argument footgun.
Full Changelog: v0.1.1...v0.1.2