Skip to content

biome check --write --unsafe hangs indefinitely with noCommentText fix #9196

@Bug-Finderr

Description

@Bug-Finderr

Environment

  • Biome version: 2.4.4
  • OS: macOS (Darwin 25.3.0)

Description

biome check --write --unsafe hangs indefinitely when a TSX file has a noCommentText violation. The unsafe fix (// comment{/* comment */}) creates an infinite fix cycle.

  • biome check → reports error, exits normally
  • biome check --write → skips unsafe fix, exits normally
  • biome check --write --unsafehangs forever

Reproduction

Playground link

mkdir /tmp/biome-repro && cd /tmp/biome-repro

cat > biome.json << 'EOF'
{
  "formatter": { "enabled": true, "indentStyle": "space", "indentWidth": 2 },
  "linter": { "enabled": true, "rules": { "recommended": true } }
}
EOF

cat > test.tsx << 'EOF'
export default function Foo() {
  return (
    <div>
      <p>// comment</p>
    </div>
  );
}
EOF

biome check --write --unsafe test.tsx
# Hangs — kill with Ctrl+C

Metadata

Metadata

Assignees

No one assigned

    Labels

    S-Needs triageStatus: this issue needs to be triaged

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions