Skip to content

Commit

Permalink
Updated diagnostics section with desciption of issue #60
Browse files Browse the repository at this point in the history
  • Loading branch information
jonasbn committed Aug 18, 2021
1 parent b988a90 commit 6af0b82
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ repos:
rev: v0.5.0
hooks:
- id: spellcheck
name: "Checking spelling using pyspelling"
- repo: https://github.com/igorshubovych/markdownlint-cli
rev: v0.27.1
hooks:
- id: markdownlint
name: "Checking Markdown with markdownlint"
name: "Checking Markdown using markdownlint"
51 changes: 51 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -435,6 +435,57 @@ And you can then put these to use in your configuration. The example below outli

Please see the repository's `requirements.txt` for a list of all included Python modules and their exact versions.

### Diagnostic text: `ValueError: Pipline step in unexpected format:`

This error emitted from `pyspelling` indicates issues with the configuration file.

Please see the section: "Configuration" above.

With the update of [pyspelling](https://pypi.org/project/pyspelling/) from 2.6.1 to 2.7.3 with release 0.16.0 (0.15.0, do see the change log).

This error would be emitted from the GitHub Action, if the configuration was not properly formatted. The Markdown example's earlier revisions in this repository would demonstrate the error.

To address the error, the options below the filter should be properly indented.

```yaml
- pyspelling.filters.html:
comments: false
ignores:
- code
- pre
```

Should be indented to:

```yaml
- pyspelling.filters.html:
comments: false
ignores:
- code
- pre
```

The complete error emitted could would look something along the lines of:

```text
Traceback (most recent call last):
File "/usr/local/bin/pyspelling", line 8, in <module>
sys.exit(main())
File "/usr/local/lib/python3.9/site-packages/pyspelling/__main__.py", line 30, in main
return run(
File "/usr/local/lib/python3.9/site-packages/pyspelling/__main__.py", line 55, in run
for results in spellcheck(
File "/usr/local/lib/python3.9/site-packages/pyspelling/__init__.py", line 673, in spellcheck
for result in spellchecker.run_task(task, source_patterns=sources):
File "/usr/local/lib/python3.9/site-packages/pyspelling/__init__.py", line 311, in run_task
self._build_pipeline(task)
File "/usr/local/lib/python3.9/site-packages/pyspelling/__init__.py", line 255, in _build_pipeline
raise ValueError(STEP_ERROR.format(str(step)))
ValueError: Pipline step in unexpected format: {'pyspelling.filters.html': None, 'comments': False, 'ignores': ['code', 'pre']}
```

Example lifted from issue [#60](https://github.com/rojopolis/spellcheck-github-actions/issues/60)

## DockerHub

This action is based on a Docker image available on DockerHub.
Expand Down

0 comments on commit 6af0b82

Please sign in to comment.