Prefix do not work pattern?
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 1.6k
- Forks
- 62
- PR merge metrics
- No merged PRs in 30d
Description
Summary
When work yamllint and actionlint under efm-langerver.
yamllint message inlucde prefix.
actionlint message do not include prefix.
test setting
efm-langserver setting
version: 2
tools:
yamllint-lint: &yamllint-lint
prefix: yamllint
lint-command: 'yamllint --strict --format parsable ${INPUT}'
lint-stdin: false
lint-formats:
- '%f:%l:%c: [%t%*[a-z]] %m'
env:
- 'PYTHONIOENCODING=UTF-8'
actionlint-lint: &actionlint-lint
prefix: actionlint
lint-command: "bash -c \"[[ '${INPUT}' =~ \\\\.github/workflows/ ]]\" && actionlint -oneline -no-color -"
lint-stdin: true
lint-formats:
- '%f:%l:%c: %m'
root-markers:
- .github
languages:
yaml:
- <<: *yamllint-lint
- <<: *actionlint-lint
see also tsuyoshicho/vim-efm-langserver-settings latest
target file (OK)
on: push
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: test
run:
echo "test"
# Actionlint : no error
vim quickfix result
.github\workflows\actionlint_ok.yml|1 col 1 warning| Warning:[yamllint] missing document start "---" (document-start)
.github\workflows\actionlint_ok.yml|1 col 1 warning| Warning:[yamllint] truthy value should be one of [false, true] (truthy)
.github\workflows\actionlint_ok.yml|1 col 9 error| Error:[yamllint] wrong new line character: expected \n (new-lines)
target file (NG)
on: pop
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: test
run:
echo "test"
# Actionlint : error occur
# .github\workflows\actionlint_ok.yml|1 col 5 error| Error:1:Value is not accepted. Valid values:...
(for .github/workflows/actionlint_ng.yml)
vim quickfix result
.github\workflows\actionlint_ng.yml|1 col 5 error| Error:1:Value is not accepted. Valid values: "check_run", "check_suite", "create", "delete", "deployment", "deployment_status", "discussion", "discussion_comment", "fork", "gollum", "issue_comment", "issues", "label", "member", "milestone", "page_build", "project", "project_card", "project_column", "public", "pull_request", "pull_request_review", "pull_request_review_comment", "pull_request_target", "push", "registry_package", "release", "status", "watch", "workflow_dispatch", "workflow_run", "repository_dispatch".
.github\workflows\actionlint_ng.yml|1 col 1 warning| Warning:[yamllint] missing document start "---" (document-start)
.github\workflows\actionlint_ng.yml|1 col 1 warning| Warning:[yamllint] truthy value should be one of [false, true] (truthy)
.github\workflows\actionlint_ng.yml|1 col 8 error| Error:[yamllint] wrong new line character: expected \n (new-lines)
.github\workflows\actionlint_ng.yml|11 col 81 error| Error:[yamllint] line too long (110 > 80 characters) (line-length)
or use test file repo
https://github.com/tsuyoshicho/action-test-repo/tree/test/efm-actionlint
Expect result
prefix work fine
.github\workflows\actionlint_ng.yml|1 col 5 error| Error:1:[actionlint] Value is not accepted. Valid values: "check_run", "check_suite", "create", "delete", "deployment", "deployment_status", "discussion", "discussion_comment", "fork", "gollum", "issue_comment", "issues", "label", "member", "milestone", "page_build", "project", "project_card", "project_column", "public", "pull_request", "pull_request_review", "pull_request_review_comment", "pull_request_target", "push", "registry_package", "release", "status", "watch", "workflow_dispatch", "workflow_run", "repository_dispatch".
Actual result
- yamllint with prefix message
- actionlint without prefix message
.github\workflows\actionlint_ng.yml|1 col 5 error| Error:1:Value is not accepted. Valid values: "check_run", "check_suite", "create", "delete", "deployment", "deployment_status", "discussion", "discussion_comment", "fork", "gollum", "issue_comment", "issues", "label", "member", "milestone", "page_build", "project", "project_card", "project_column", "public", "pull_request", "pull_request_review", "pull_request_review_comment", "pull_request_target", "push", "registry_package", "release", "status", "watch", "workflow_dispatch", "workflow_run", "repository_dispatch".
First line actionlint error message, do not contain [actionlint] .
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the issue with the efm-langserver configuration and the tsuyoshicho/action-test-repo test case, comparing yamllint and actionlint diagnostics. Trace where the configured prefix is applied to lint-formats output; done when actionlint diagnostics include [actionlint] without changing the existing yamllint behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100