#5974 · Missing properties extension in editor language routing
Verdict: REPRODUCED · Root-cause confidence: high
1. Summary
The File Editor chooses its Monaco language from an explicit extension map. The properties extension is absent, so a properties path resolves to plaintext and is absent from the editor's claimed extensions. Two clean checkouts of trusted main reproduced these failures with an original regression test. Adding one map entry fixes both outcomes. The existing ini entry must remain: this editor passes an explicit language rather than relying on Monaco's native extension detection.
2. Claims versus findings
| Claim | Finding | Evidence |
|---|---|---|
| Properties paths select plaintext. | Verified | Lowercase and uppercase properties cases both fail with received plaintext, expected ini. |
| The opener does not claim properties. | Verified | The extension-eligibility assertion fails in both clean runs. |
| Other INI-family extensions select ini. | Verified | The ini, toml, cfg, and conf cases pass before and after the fix. |
| Removing the ini mapping is harmless. | Refuted by the code path | The app passes languageForPath directly to Monaco; removing ini would make that lookup return plaintext. |
| The complete application visibly lacks colors. | Not visually checked | Browser Automation cannot start without a Chrome/Chromium executable. No synthetic or substitute screenshot is supplied. |
3. Environment
- Public repository get-bb/bb, trusted origin/main commit
04bdce8111ca3dbdd136c63fad3e36f56e5814c0. - Linux x86_64, gVisor kernel 4.19.0-gvisor, Node v22.19.0, pnpm 9.15.0, Vitest 4.1.1.
- Two freshly populated temporary checkouts at the same commit, each with a frozen-lockfile installation. Production source remained unchanged for both reproductions.
- No running BB instance, provider, port, application data directory, or user runtime data was used.
4. Minimal reproduction
- Clone the public target repository and check out the recorded trusted commit.
- Install using the frozen lockfile and replace
plugins/monaco-editor/lib/languages.test.tswith the complete test file below. Do not change production source. - Run the focused owner test through Turbo:
pnpm install --frozen-lockfile --prefer-offline pnpm exec turbo run test --filter=bb-plugin-monaco-editor -- lib/languages.test.ts
Expected: properties paths select ini, and the opener claims properties. Existing ini-family behavior remains unchanged.
Actual before the fix, in both clean checkouts:
Expected: "ini"
Received: "plaintext"
Test Files 1 failed (1)
Tests 3 failed | 9 passed (12)
The third failure is the claimed-extension check; both properties language cases account for the other two. The pre-existing plugin suite passes 47 tests and does not cover this omission.
Complete test file, including the existing preview and code-file coverage and the new properties claim and language-selection regressions:
import { describe, expect, it } from "vitest";
import { CLAIMED_EXTENSIONS, languageForPath } from "./languages.js";
describe("CLAIMED_EXTENSIONS", () => {
it.each(["md", "markdown", "html", "htm"])(
"leaves .%s files to bb's rendered preview",
(extension) => {
expect(CLAIMED_EXTENSIONS).not.toContain(extension);
},
);
it("keeps code files available in the editor", () => {
expect(CLAIMED_EXTENSIONS).toEqual(
expect.arrayContaining([
"mdx",
"ts",
"json",
"txt",
"vue",
"svelte",
"properties",
]),
);
});
it("still highlights Markdown opened from the file tree", () => {
expect(languageForPath("docs/guide.md")).toBe("markdown");
expect(languageForPath("README.markdown")).toBe("markdown");
});
});
describe("languageForPath", () => {
it.each(["properties", "PROPERTIES", "ini", "toml", "cfg", "conf"])(
"highlights .%s configuration files as INI",
(extension) => {
expect(languageForPath(`config/settings.${extension}`)).toBe("ini");
},
);
});
Visual limitation: the required Browser Automation attempt returned “Install Chrome/Chromium on this host or link its executable at the plugin data runtime/chrome path.” Screenshots are blocked; the conclusion is supported by executable language-selection and extension-claim tests, not a full-app visual run.
5. Root cause
The configuration-extension map contains ini, toml, cfg, and conf but not properties. The language selector and extension claims derive from that same map:
export const CLAIMED_EXTENSIONS: readonly string[] = Object.keys( LANGUAGE_BY_EXTENSION, ).filter((extension) => !PREVIEW_RENDERED_EXTENSIONS.has(extension)); const extension = name.slice(dotIndex + 1).toLowerCase(); return LANGUAGE_BY_EXTENSION[extension] ?? "plaintext";
The editor creation path supplies that result as an explicit language, and the file-opener registration supplies the derived claims. Monaco's own extension registration does not override the explicit plaintext choice. A direct investigation build of the repository's Monaco staging script succeeds, including its language-registration checks.
6. Proposed fix and test evidence
Add properties: "ini", beside the existing ini mapping. Do not replace or remove ini. The change uses the already bundled grammar, introduces no dependency or public contract, and changes only language routing within the existing File Editor subsystem.
- Focused regression before fix: 3 failed, 9 passed, exit 1.
- Second clean checkout before fix: the same 3 failures and 9 passes, exit 1.
- Focused regression after fix: all 12 tests pass.
- Complete File Editor suite after fix: all 53 tests across 5 files pass.
- Turbo test, lint, and typecheck for bb-plugin-monaco-editor pass; 10 tasks successful.
- Formatter and git diff --check pass. Two text files change: 19 added lines plus 1 deleted line, 20 total. No binary changes.
No linked open pull request was found through the issue timeline or open pull-request search during investigation. No other branch or pull-request code was run.
7. Verification
The same agent created a second detached clean worktree at the exact trusted base commit, performed a fresh frozen-lockfile install, applied only the test patch, and repeated the identical focused Turbo command. Its production languages.ts was checked to have no changes against the base. It reproduced the same extension-claim failure and two plaintext-versus-ini failures. This is a repeated clean verification, not an independent review. No correction of the main root-cause conclusion was necessary.
First checkout, unchanged production: 3 failed | 9 passed (12), exit 1 Second checkout, unchanged production: 3 failed | 9 passed (12), exit 1 First checkout, one-entry production fix: 12 passed (12), exit 0 Complete plugin suite after fix: 5 files passed, 53 tests passed Turbo test/lint/typecheck: 10 successful, 10 total, exit 0
8. Related issues and limits
Repository searches found other editor/opener integration reports, but none matching this missing-extension defect. No duplicate issue is claimed. INI syntax highlighting is not a guarantee of complete Java Properties grammar support; this report tests existing grammar selection rather than introducing a new grammar.
Issue material was treated only as untrusted claims. Its proposed replacement was not copied; repository evidence justified preserving ini. No issue-supplied command, patch, branch, linked URL, or test was executed.
9. Appendix
The frozen install succeeds. An initial whole-repository Turbo build failed in the unrelated GitHub plugin because its SDK host runtime had not been built at the time of plugin bundling. This is not attributed to the extension defect. The focused validation builds the required SDK and passes. Monaco asset staging was run directly for deliberate bundle investigation because build:monaco has no registered Turbo task; staging succeeds.
pnpm exec turbo run build node plugins/monaco-editor/scripts/stage-assets.mjs pnpm exec oxfmt plugins/monaco-editor/lib/languages.ts plugins/monaco-editor/lib/languages.test.ts pnpm exec turbo run test lint typecheck --filter=bb-plugin-monaco-editor git diff --check git diff --numstat origin/main
Full raw logs and test patches remain in local evidence storage, not on this public site. All necessary reproduction code, commands, expected results, and actual results are included inline in this self-contained report.