From e3b7ff2f1f9648552dfa6891c452f1266ab91ab4 Mon Sep 17 00:00:00 2001 From: Radek Sienkiewicz Date: Sun, 15 Mar 2026 02:58:59 +0100 Subject: [PATCH] Docs: fix MDX markers blocking page refreshes (#46695) Merged via squash. Prepared head SHA: 56b25a9fb3acc1a3befbf33c28a6d27df8aca8ef Co-authored-by: velvet-shark <126378+velvet-shark@users.noreply.github.com> Co-authored-by: velvet-shark <126378+velvet-shark@users.noreply.github.com> Reviewed-by: @velvet-shark --- CHANGELOG.md | 1 + docs/concepts/model-providers.md | 11 +++-------- docs/perplexity.md | 2 +- docs/providers/moonshot.md | 11 +++-------- docs/tools/exec-approvals.md | 5 +++-- scripts/sync-moonshot-docs.ts | 10 +++++----- src/infra/exec-safe-bin-policy.test.ts | 4 ++-- 7 files changed, 18 insertions(+), 26 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9d47e75bcfa..4f901df8e27 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -28,6 +28,7 @@ Docs: https://docs.openclaw.ai - Control UI/dashboard: preserve structured gateway shutdown reasons across restart disconnects so config-triggered restarts no longer fall back to `disconnected (1006): no reason`. (#46532) Thanks @vincentkoc. - Feishu/topic threads: fetch full thread context, including prior bot replies, when starting a topic-thread session so follow-up turns in Feishu topics keep the right conversation state. Thanks @Coobiw. - Browser/profiles: drop the auto-created `chrome-relay` browser profile; users who need the Chrome extension relay must now create their own profile via `openclaw browser create-profile`. (#45777) Thanks @odysseus0. +- Docs/Mintlify: fix MDX marker syntax on Perplexity, Model Providers, Moonshot, and exec approvals pages so local docs preview no longer breaks rendering or leaves stale pages unpublished. (#46695) Thanks @velvet-shark. ## 2026.3.13 diff --git a/docs/concepts/model-providers.md b/docs/concepts/model-providers.md index a502240226e..cf2b5229cf8 100644 --- a/docs/concepts/model-providers.md +++ b/docs/concepts/model-providers.md @@ -186,20 +186,15 @@ Moonshot uses OpenAI-compatible endpoints, so configure it as a custom provider: Kimi K2 model IDs: - - -{/_ moonshot-kimi-k2-model-refs:start _/ && null} - - +[//]: # "moonshot-kimi-k2-model-refs:start" - `moonshot/kimi-k2.5` - `moonshot/kimi-k2-0905-preview` - `moonshot/kimi-k2-turbo-preview` - `moonshot/kimi-k2-thinking` - `moonshot/kimi-k2-thinking-turbo` - - {/_ moonshot-kimi-k2-model-refs:end _/ && null} - + +[//]: # "moonshot-kimi-k2-model-refs:end" ```json5 { diff --git a/docs/perplexity.md b/docs/perplexity.md index f7eccc9453e..b71f34d666b 100644 --- a/docs/perplexity.md +++ b/docs/perplexity.md @@ -16,7 +16,7 @@ If you use `OPENROUTER_API_KEY`, an `sk-or-...` key in `tools.web.search.perplex ## Getting a Perplexity API key -1. Create a Perplexity account at +1. Create a Perplexity account at [perplexity.ai/settings/api](https://www.perplexity.ai/settings/api) 2. Generate an API key in the dashboard 3. Store the key in config or set `PERPLEXITY_API_KEY` in the Gateway environment. diff --git a/docs/providers/moonshot.md b/docs/providers/moonshot.md index 3e8217bbe5b..daf9c881de5 100644 --- a/docs/providers/moonshot.md +++ b/docs/providers/moonshot.md @@ -15,20 +15,15 @@ Kimi Coding with `kimi-coding/k2p5`. Current Kimi K2 model IDs: - - -{/_ moonshot-kimi-k2-ids:start _/ && null} - - +[//]: # "moonshot-kimi-k2-ids:start" - `kimi-k2.5` - `kimi-k2-0905-preview` - `kimi-k2-turbo-preview` - `kimi-k2-thinking` - `kimi-k2-thinking-turbo` - - {/_ moonshot-kimi-k2-ids:end _/ && null} - + +[//]: # "moonshot-kimi-k2-ids:end" ```bash openclaw onboard --auth-choice moonshot-api-key diff --git a/docs/tools/exec-approvals.md b/docs/tools/exec-approvals.md index 830dfa6f159..f0fde42a178 100644 --- a/docs/tools/exec-approvals.md +++ b/docs/tools/exec-approvals.md @@ -160,13 +160,14 @@ Long options are validated fail-closed in safe-bin mode: unknown flags and ambig abbreviations are rejected. Denied flags by safe-bin profile: - +[//]: # "SAFE_BIN_DENIED_FLAGS:START" - `grep`: `--dereference-recursive`, `--directories`, `--exclude-from`, `--file`, `--recursive`, `-R`, `-d`, `-f`, `-r` - `jq`: `--argfile`, `--from-file`, `--library-path`, `--rawfile`, `--slurpfile`, `-L`, `-f` - `sort`: `--compress-program`, `--files0-from`, `--output`, `--random-source`, `--temporary-directory`, `-T`, `-o` - `wc`: `--files0-from` - + +[//]: # "SAFE_BIN_DENIED_FLAGS:END" Safe bins also force argv tokens to be treated as **literal text** at execution time (no globbing and no `$VARS` expansion) for stdin-only segments, so patterns like `*` or `$HOME/...` cannot be diff --git a/scripts/sync-moonshot-docs.ts b/scripts/sync-moonshot-docs.ts index c5afc543cfd..b1c05b2ec56 100644 --- a/scripts/sync-moonshot-docs.ts +++ b/scripts/sync-moonshot-docs.ts @@ -51,7 +51,7 @@ function replaceBlockLines( } function renderKimiK2Ids(prefix: string) { - return MOONSHOT_KIMI_K2_MODELS.map((model) => `- \`${prefix}${model.id}\``); + return [...MOONSHOT_KIMI_K2_MODELS.map((model) => `- \`${prefix}${model.id}\``), ""]; } function renderMoonshotAliases() { @@ -90,8 +90,8 @@ async function syncMoonshotDocs() { let moonshotText = await readFile(moonshotDoc, "utf8"); moonshotText = replaceBlockLines( moonshotText, - "{/_ moonshot-kimi-k2-ids:start _/ && null}", - "{/_ moonshot-kimi-k2-ids:end _/ && null}", + '[//]: # "moonshot-kimi-k2-ids:start"', + '[//]: # "moonshot-kimi-k2-ids:end"', renderKimiK2Ids(""), ); moonshotText = replaceBlockLines( @@ -110,8 +110,8 @@ async function syncMoonshotDocs() { let conceptsText = await readFile(conceptsDoc, "utf8"); conceptsText = replaceBlockLines( conceptsText, - "{/_ moonshot-kimi-k2-model-refs:start _/ && null}", - "{/_ moonshot-kimi-k2-model-refs:end _/ && null}", + '[//]: # "moonshot-kimi-k2-model-refs:start"', + '[//]: # "moonshot-kimi-k2-model-refs:end"', renderKimiK2Ids("moonshot/"), ); diff --git a/src/infra/exec-safe-bin-policy.test.ts b/src/infra/exec-safe-bin-policy.test.ts index b723d2301f3..4af387b73dc 100644 --- a/src/infra/exec-safe-bin-policy.test.ts +++ b/src/infra/exec-safe-bin-policy.test.ts @@ -10,8 +10,8 @@ import { validateSafeBinArgv, } from "./exec-safe-bin-policy.js"; -const SAFE_BIN_DOC_DENIED_FLAGS_START = ""; -const SAFE_BIN_DOC_DENIED_FLAGS_END = ""; +const SAFE_BIN_DOC_DENIED_FLAGS_START = '[//]: # "SAFE_BIN_DENIED_FLAGS:START"'; +const SAFE_BIN_DOC_DENIED_FLAGS_END = '[//]: # "SAFE_BIN_DENIED_FLAGS:END"'; function buildDeniedFlagArgvVariants(flag: string): string[][] { const value = "blocked";