gabriel / muse public
pyproject.toml
134 lines 3.8 KB
dec4604a feat(mwp): replace JSON+base64 wire protocol with MWP binary msgpack Gabriel Cardona <gabriel@tellurstori.com> 13h ago
1 [project]
2 name = "muse"
3 version = "0.1.5"
4 description = "Muse — domain-agnostic version control for multidimensional state"
5 readme = "README.md"
6 license = {text = "MIT"}
7 requires-python = ">=3.14"
8 dependencies = [
9 "typer>=0.24.0",
10 # Binary wire protocol — eliminates base64 overhead for object transfers.
11 "msgpack>=1.1",
12 "mido>=1.3.3",
13 "defusedxml>=0.7.1",
14 # tree-sitter: professional AST parsing for the code domain plugin.
15 # Used by GitHub Copilot, VS Code, Neovim, and Zed — the industry standard.
16 "tree-sitter>=0.25.0",
17 "tree-sitter-javascript>=0.25.0",
18 "tree-sitter-typescript>=0.23.2",
19 "tree-sitter-java>=0.23.5",
20 "tree-sitter-go>=0.25.0",
21 "tree-sitter-rust>=0.24.0",
22 "tree-sitter-c>=0.24.1",
23 "tree-sitter-cpp>=0.23.4",
24 "tree-sitter-c-sharp>=0.23.1",
25 "tree-sitter-ruby>=0.23.1",
26 "tree-sitter-kotlin>=1.1.0",
27 # Prose and web language grammars.
28 "tree-sitter-markdown>=0.5.1",
29 "tree-sitter-html>=0.23.2",
30 "tree-sitter-css>=0.25.0",
31 # Swift: py-tree-sitter-swift must be built from source; omitted here to
32 # avoid breaking CI on machines without Xcode CLT. Install manually with:
33 # pip install py-tree-sitter-swift
34 # The adapter degrades gracefully to file-level tracking without it.
35 ]
36
37 [project.scripts]
38 muse = "muse.cli.app:main"
39
40 [project.optional-dependencies]
41 dev = [
42 "pytest>=9.0.2",
43 "pytest-asyncio>=1.3.0",
44 "pytest-cov>=7.0.0",
45 "anyio>=4.12.0",
46 "mypy>=1.19.1",
47 "hypothesis>=6.100.0",
48 "types-defusedxml>=0.7.0.20240218",
49 ]
50
51 [build-system]
52 requires = ["hatchling>=1.29.0"]
53 build-backend = "hatchling.build"
54
55 [tool.pytest.ini_options]
56 asyncio_mode = "auto"
57 testpaths = ["tests"]
58 cache_dir = "/tmp/pytest_cache"
59 addopts = "-v --tb=short"
60
61 [tool.coverage.run]
62 source = ["muse"]
63 omit = [
64 # Hub/remote authentication — future feature, requires network fixtures
65 "muse/cli/config.py",
66 # MIDI binary parser — requires MIDI fixture files to test meaningfully
67 "muse/cli/midi_parser.py",
68 # Backward-compat re-export shim — trivially thin wrapper
69 "muse/cli/models.py",
70 ]
71
72 [tool.coverage.report]
73 exclude_lines = [
74 "pragma: no cover",
75 "if TYPE_CHECKING:",
76 "raise NotImplementedError",
77 ]
78
79 [tool.mypy]
80 python_version = "3.14"
81 strict = true
82 explicit_package_bases = true
83 namespace_packages = true
84 warn_unreachable = true
85 show_error_codes = true
86 # Exclude deferred files not yet ported to the strict typed surface.
87 exclude = [
88 "muse/plugins/music/services/",
89 "muse/cli/commands/emotion_diff\\.py",
90 "muse/cli/commands/groove_check\\.py",
91 ]
92
93 [[tool.mypy.overrides]]
94 module = ["tests.*"]
95 disallow_untyped_decorators = false
96 disallow_untyped_defs = false
97 disallow_incomplete_defs = false
98
99 [[tool.mypy.overrides]]
100 module = ["mido"]
101 ignore_missing_imports = true
102
103 [[tool.mypy.overrides]]
104 module = ["msgpack"]
105 ignore_missing_imports = true
106
107 [[tool.mypy.overrides]]
108 # tree-sitter and its grammar packages ship compiled C extensions. The core
109 # package (tree_sitter) provides py.typed stubs when run via `python -m mypy`
110 # from the project venv, but a globally-installed mypy cannot resolve them.
111 # Grammar packages never ship stubs. Marking all of them ignore_missing_imports
112 # keeps both invocation styles green; the venv mypy still validates our usage
113 # against the stubs when they are findable (CI).
114 module = [
115 "tree_sitter",
116 "tree_sitter_javascript",
117 "tree_sitter_typescript",
118 "tree_sitter_java",
119 "tree_sitter_go",
120 "tree_sitter_rust",
121 "tree_sitter_c",
122 "tree_sitter_cpp",
123 "tree_sitter_c_sharp",
124 "tree_sitter_ruby",
125 "tree_sitter_kotlin",
126 "tree_sitter_markdown",
127 "tree_sitter_html",
128 "tree_sitter_css",
129 "py_tree_sitter_swift",
130 ]
131 ignore_missing_imports = true
132
133 [tool.hatch.build.targets.wheel]
134 packages = ["muse"]