Fix JavaScript lint errors

未关闭
#16,126 2 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

@B-Payal 已经在做这个了。

开始于 2026年10月14日。

  • #16139 来自 @B-Payal —— 未关闭

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
25/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
活跃
技术栈
eslint, javascript
领域
tooling

调研方向

The failures are in the example files named in the log, such as lib/node_modules/@stdlib/assert/is-configurable-property-in/examples/index.js (eol-open-bracket-spacing) and lib/node_modules/@stdlib/string/remove-utf8-bom/examples/index.js (doctest). Read the log's line numbers, then run the JavaScript lint target for those files. Done means those files lint clean. Pull request #16139 is already open against this issue, so check it before starting.

由索引模型根据 Issue 内容生成。

描述

Good First Issue

JavaScript Linting Failures

Linting failures were detected in the automated JavaScript lint workflow run.

Workflow Details
Error Details
make[1]: Entering directory '/home/runner/work/stdlib/stdlib'

Linting file: lib/node_modules/@stdlib/assert/is-relative-uri/examples/index.js

Linting file: lib/node_modules/@stdlib/array/base/fancy-slice/examples/index.js

Linting file: lib/node_modules/@stdlib/string/examples/index.js

Linting file: lib/node_modules/@stdlib/assert/is-configurable-property-in/examples/index.js

/home/runner/work/stdlib/stdlib/lib/node_modules/@stdlib/assert/is-configurable-property-in/examples/index.js
25:12  error  No spaces allowed between an opening parenthesis or bracket and a nested object or array expression at the end of a line  stdlib/eol-open-bracket-spacing
33:8   error  No spaces allowed between an opening parenthesis or bracket and a nested object or array expression at the end of a line  stdlib/eol-open-bracket-spacing
37:8   error  No spaces allowed between an opening parenthesis or bracket and a nested object or array expression at the end of a line  stdlib/eol-open-bracket-spacing

✖ 3 problems (3 errors, 0 warnings)
3 errors and 0 warnings potentially fixable with the `--fix` option.

Linting failed.

Linting file: lib/node_modules/@stdlib/string/remove-utf8-bom/examples/index.js

/home/runner/work/stdlib/stdlib/lib/node_modules/@stdlib/string/remove-utf8-bom/examples/index.js
27:1  error  Displayed return value is `boop\ufeff`, but expected `boop` instead    stdlib/doctest
31:1  error  Displayed return value is `be\ufeffbop`, but expected `bebop` instead  stdlib/doctest

✖ 2 problems (2 errors, 0 warnings)
2 errors and 0 warnings potentially fixable with the `--fix` option.

Linting failed.

Linting file: lib/node_modules/@stdlib/stats/array/meanpn/examples/index.js

Linting file: lib/node_modules/@stdlib/process/umask/examples/index.js

Linting file: lib/node_modules/@stdlib/stats/base/ndarray/dvariance/examples/index.js

Linting file: lib/node_modules/@stdlib/stats/base/dists/normal/skewness/examples/index.js
μ: 1.9581, σ: 16.6563, skew(X;μ,σ): 0.0000
μ: -1.5429, σ: 17.6018, skew(X;μ,σ): 0.0000
μ: 3.9191, σ: 8.4898, skew(X;μ,σ): 0.0000
μ: 0.6959, σ: 0.5511, skew(X;μ,σ): 0.0000
μ: 4.5132, σ: 2.1367, skew(X;μ,σ): 0.0000
μ: -1.9799, σ: 19.3472, skew(X;μ,σ): 0.0000
μ: -3.1450, σ: 0.8523, skew(X;μ,σ): 0.0000
μ: -3.4725, σ: 18.1537, skew(X;μ,σ): 0.0000
μ: 0.0781, σ: 15.3200, skew(X;μ,σ): 0.0000
μ: 4.1261, σ: 2.6463, skew(X;μ,σ): 0.0000

Linting file: lib/node_modules/@stdlib/utils/omit-by/examples/index.js

Linting file: lib/node_modules/@stdlib/blas/ext/base/ssort2sh/examples/index.js
make[1]: *** [/home/runner/work/stdlib/stdlib/tools/make/lib/lint/javascript/eslint.mk:261: eslint-files] Error 1
make[1]: Leaving directory '/home/runner/work/stdlib/stdlib'
make: *** [/home/runner/work/stdlib/stdlib/tools/make/lib/lint/javascript/Makefile:158: lint-javascript-files] Error 2
Pull Request Instructions
  • Please use the following PR title format:
    "chore: fix JavaScript lint errors (issue #<ISSUE_NUMBER>)".
  • Reference this issue in the "Related Issues" section of the PR body as "resolves #<ISSUE_NUMBER>".
主要语言
JavaScript
星标
6k
派生
1.3k
平均合并
1 天 21 小时
30 天内合并 PR
224

环境准备

在 Codespaces 中打开

在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

stdlib-js/stdlib 的其他 Issue

查看 stdlib-js/stdlib 的全部 Issue

相似的 Issue

更多 JavaScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。