My really simple rendition of how a linter works.
Project description
mylint
My really simple rendition of how a linter works.
This original version was written for my AST article. Since then I've added tests and turned it into a package. Check the original branch for the original version of this, that was used in the article.
Usage
mylint [...file names]
Example:
$ mylint tests/testcode.py
testcode.py:17:15: W001: Set contains duplicate item: 1
testcode.py:12:12: W001: Set contains duplicate item: 'PUT'
testcode.py:1:0: W002: Unused variable: 's'
testcode.py:5:4: W002: Unused variable: 'var'
testcode.py:17:0: W002: Unused variable: 's2'
Development / Testing
Setup a virtual environment, and install the package with:
pip install -r requirements-dev.txt
Then run pytest to run tests. Now, have fun playing with the code and tests!
Type Checking
Run mypy .
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mylint-0.1.0.tar.gz.
File metadata
- Download URL: mylint-0.1.0.tar.gz
- Upload date:
- Size: 4.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/52.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
eadbff99ea2646cc82312f592711caddfaae6837a9afcec712c8b647b26b6e58
|
|
| MD5 |
bb811da0b2e546ee99975651c5b5a2e7
|
|
| BLAKE2b-256 |
255215a1a69a1ab2ea87bdd5220e4fa6ec94de3f280397ac21e2051762b73c46
|
File details
Details for the file mylint-0.1.0-py3-none-any.whl.
File metadata
- Download URL: mylint-0.1.0-py3-none-any.whl
- Upload date:
- Size: 4.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/52.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
736b6782f6b0422f2e9fb067668e29a50cbeb97d886fd6648e44a6c973e771b3
|
|
| MD5 |
464c05af6290e12b7ddce6cb36df4aff
|
|
| BLAKE2b-256 |
d1dc5d3db6c5c3bc6c62fc56e39f16fe81bd34c35105c225877928b11e116a97
|