eslint-plugin-sql icon indicating copy to clipboard operation
eslint-plugin-sql copied to clipboard

Broken on running eslint --fix on MacOS Sonoma

Open PPan1215 opened this issue 1 year ago • 2 comments

Description

It keeps appending perl locale issue to my sql:

select
    c.*
    exclude (xxx, xxx)
from
    current_records c
    left join historical_records h on c.xxx = h.xxx
where
    c.xxx != h._h_hashed perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: LC_ALL = "C.UTF-8", LANG = (unset) are supported
    and installed on your system. perl: warning: Falling back to the standard locale ("C").perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: LC_ALL = "C.UTF-8"...

where perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: LC_ALL = "C.UTF-8", LANG = (unset) are supported gets appended after formatted sql.

Config

...
  {
    files: ["lib/**/*.ts"],
    plugins: { "sql" },
    rules: {
      "sql/format": [
        "error",
        {
          ignoreInline: true,
          ignoreTagless: true,
        }, {
          functionCase: "lowercase",
          keywordCase: "lowercase",
          spaces: 4,
        },
      ],
    },
  },
...

System version

macOS Sonoma 14.3.1 @ Apple M1 Pro

Expected behaviour

Format well without appending any warnings.

Attempted solutions in StackOverflow

  • [x] Export LANG=xx in rc profile file
  • [x] Configure locale terminal app

PPan1215 avatar Mar 07 '24 05:03 PPan1215

I have same issue. This plugin is unusable by this.

ecosse3 avatar Jun 06 '24 11:06 ecosse3

Same issue. Unusable

UgurGumushan avatar Jul 26 '24 23:07 UgurGumushan