[Bug for MCP&API]: Slashes in text break local output file saving
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 88/100
Research direction
Start in minimax_mcp/utils.py at build_output_file(), then inspect the local save path in minimax_mcp/server.py. Reproduce the issue with the provided TemporaryDirectory script and add a regression test covering text with date-style slashes. Done means both date formats produce files directly inside the requested output directory and the write succeeds.
Written by the indexing model from the issue text.
Description
Text starting with a date like 2026/10/03 breaks local output saving for
text_to_audio (MINIMAX_API_RESOURCE_MODE=local).
build_output_file() takes the first 10 characters and only replaces spaces.
The result is t2a_2026/10/03_<timestamp>.mp3. The slashes are treated as path
separators, but those directories don't exist. Changing the date to 2026-10-03
lets the file save normally.
Reproduction
Run this from the repository root with the Python dependencies installed. It
imports the unmodified utility and writes test bytes directly to a temporary
directory, without calling the API. Both inputs use the same absolute output
path, which also avoids the separate path-joining issue.
from pathlib import Path
from tempfile import TemporaryDirectory
from minimax_mcp.utils import build_output_file, build_output_path
records = []
with TemporaryDirectory() as directory:
output_path = build_output_path(str(Path(directory) / "output"))
for text in ("2026-10-03", "2026/10/03"):
output_file = build_output_file("t2a", text, output_path, "mp3")
output_path.parent.mkdir(parents=True, exist_ok=True)
try:
with open(output_path / output_file, "wb") as stream:
stream.write(b"local write probe")
result = "saved"
except OSError as error:
result = type(error).__name__
parent_matches = output_file.parent == output_path
print(text, "parent_matches:", parent_matches, "write:", result)
records.append({"text": text, "parent_matches": parent_matches, "write": result})
Both runs gave this output:
2026-10-03 parent_matches: True write: saved
2026/10/03 parent_matches: False write: FileNotFoundError
Both inputs should save directly inside the requested directory.
Environment
Windows, Python 3.11.9, package version 0.0.19 at
0856b9aef8a9d676bb63bdd6b6426d7b640a3b7a.
Models used and Trace-ID: N/A (local reproduction, no request).
The relevant code is filename construction
and the local audio save path.
I've checked the Python/JS READMEs, MCP guide and existing issues. #73/#74 address
repeated path joining, and #92 covers nested-directory writability; none changes
how text becomes a filename.
Would you be open to a small fix that replaces path separators in the text,
keeps ordinary Unicode characters, and adds a file-write regression test?
- Dominant language
- Python
- Stars
- 1.6k
- Forks
- 284
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from MiniMax-AI/MiniMax-MCP
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
MiniMax-AI/MiniMax-MCP#89 · 1 comment ·
-
bug(server): text_to_audio validates text outside try/except, inconsistent with other toolsPossibly taken @cnYui claimed this 121 days ago. Open
Difficulty 1/5 1-3 hours Newbie friendliness 82/100
MiniMax-AI/MiniMax-MCP#88 ·
-
Information disclosure for `play_audio`Possibly taken @TumCucTom claimed this 126 days ago. Open
Difficulty 1/5 Under an hour Newbie friendliness 78/100
MiniMax-AI/MiniMax-MCP#78 ·
-
fix(server): music_generation has inconsistent indentation — try block indented inside function bodyPossibly taken @TumCucTom claimed this 126 days ago. Open
Difficulty 1/5 Under an hour Newbie friendliness 88/100
MiniMax-AI/MiniMax-MCP#69 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 35/100
MiniMax-AI/MiniMax-MCP#105 · 1 comment ·
All issues in MiniMax-AI/MiniMax-MCP
Similar issues
-
needs-human needs-triage
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
gke-labs/kube-agents#2400 · 1 comment ·
Maintainers usually reply within 1 day
-
Device Details tables: FS/SF columns contradict each other (nfet_01v8 Vt row, pfet_01v8 Idsat row)Open
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
google/skywater-pdk#450 ·
-
Drained trajectory arrays are overwritten when the sequence buffer is reusedPossibly taken @sylvesterkaczmarek claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
google-deepmind/bsuite#56 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
LearningCircuit/local-deep-research#7206 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
chingu-voyages/V62-tier3-team-33#285 ·
Maintainers usually reply within 1 day