Saravanan666/pypi-org huggingface dataset:
Package: lint
Python script to automatically lint new reviews to gerrit. Designed to
be run from within Jenkins via the Gerrit Trigger pluginLint is a python package to assist with automatic code reviews. It
provides the following tools:Get a list of files changed between the active gerrit branch and the
specified gerrit review.Lint the original files in the active gerrit branch.Checkout the current review IDLint the changed files.Analyze the results according to specified validators.Post the results of the validation to gerrit via SSH (+1/-1 score
assigned, including a message).Lint uses the environmental variables set by Gerrit Trigger to do almost
all of the configuration. You can still use it via command-line (with
options!) for manual testing.You can also add a checkers to validators, which are simple functions to
compare lint data that are passed to the validator.Installationpip install git+https://github.com/astraw38/LintUsageFor pylint, just use ‘gpylinter.py’. It by default will use the
‘Pylinter’ plugin for .py files, as well as the default pylint
validators.Lint provides the ability to plugin your own Linter or Validator
classes. All you need to do is runLintFactory.register_linter(NewLinter())orValidatorFactory.register_validator(NewValidator())When you run ‘run_linters()’ or ‘run_validators()’, it’ll pick them up
and use them. Your new Linters should derive from BaseLinter, and your
new Validators should derive from BaseValidator.You can also customize the order of operations, or how comments/scores
are posted to gerrit. Just look at gpylinter as an example.
Package: lint-along
Copyright (c) 2018 FowbiPermission is hereby granted, free of charge, to any person obtaining a copyof this software and associated documentation files (the "Software"), to dealin the Software without restriction, including without limitation the rightsto use, copy, modify, merge, publish, distribute, sublicense, and/or sellcopies of the Software, and to permit persons to whom the Software isfurnished to do so, subject to the following conditions:The above copyright notice and this permission notice shall be included in allcopies or substantial portions of the Software.THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS ORIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THEAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHERLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THESOFTWARE.Description: lint-along===============Lint and commit with an adjusted linting song as message.Why?----I always make some stupid mistakes against the style guide, and because I never bothered to fix my half-baked lintersetup for VIM and I apparently feel too smart for githooks, I always end up linting my code after I made it into a PR.So instead of giving those commits a bland message I opted for some music inspired titles, and lint-along was born.Installation------------pip:.. code:: bashpip install lint-alongFrom source:.. code:: bashpython setup.py installUsage-----Execute `lint-along` in a git enabled directory... code:: bashlint-alongPlaylist--------The hits that make bland linting commits :sparkles:`Spotify <https://open.spotify.com/user/tobi.beernaert/playlist/7e3T6T18e4JVl01Vasgf3m?si=qvLwEknoQqSD5kMabwxoEA>`_Todo====- Pass the linter command via [yet another] config file.- Some documentation would be nice- Some tests would also be nice- Add more songsdisclaimer: probably really buggy, so use with cautious.Keywords: lint-alongPlatform: UNKNOWNClassifier: Development Status :: 4 - BetaClassifier: Intended Audience :: DevelopersClassifier: Natural Language :: EnglishClassifier: Operating System :: OS IndependentClassifier: Programming Language :: PythonProgramming Language :: Python :: 3.7Classifier: Topic :: Software Development :: Libraries :: Python Modules
Package: lintaosp
lintaospIntroductionlintaospis a lint worker oflintflowon AOSP written in Python.PrerequisitesAndroid lint >= 4.1.0gRPC >= 1.36.0Python >= 3.7.0RunLocal modegitclonehttps://github.com/craftslab/lintaosp.gitcdlintaosp
pipinstall-Urrequirements.txt
pythonaosp.py--config-file="config.yml"--lint-project="project"--output-file="output.json"Service modegitclonehttps://github.com/craftslab/lintaosp.gitcdlintaosp
pipinstall-Urrequirements.txt
pythonaosp.py--config-file="config.yml"--listen-url="127.0.0.1:9090"DockerLocal modegitclonehttps://github.com/craftslab/lintaosp.gitcdlintaosp
dockerbuild--no-cache-fDockerfile-tcraftslab/lintaosp:latest.
dockerrun-it-v/tmp:/tmpcraftslab/lintaosp:latest./lintaosp--config-file="config.yml"--lint-project="/tmp/project"--output-file="/tmp/output.json"Service modegitclonehttps://github.com/craftslab/lintaosp.gitcdlintaosp
dockerbuild--no-cache-fDockerfile-tcraftslab/lintaosp:latest.
dockerrun-it-p9090:9090craftslab/lintaosp:latest./lintaosp--config-file="config.yml"--listen-url="127.0.0.1:9090"Usageusage: aosp.py [-h] --config-file CONFIG_FILE
               [--lint-project LINT_PROJECT | --listen-url LISTEN_URL]
               [--output-file OUTPUT_FILE] [-v]

Lint AOSP

optional arguments:
  -h, --help            show this help message and exit
  --config-file CONFIG_FILE
                        config file (.yml)
  --lint-project LINT_PROJECT
                        lint project (/path/to/project)
  --listen-url LISTEN_URL
                        listen url (host:port)
  --output-file OUTPUT_FILE
                        output file (.json|.txt|.xlsx)
  -v, --version         show program's version number and exitSettingslintaospparameters can be set in the directoryconfig.An example of configuration inconfig.yml:apiVersion:v1kind:workermetadata:name:lintaospspec:sdk:-Correctness-Correctness:Messages-Security-Compliance-Performance-Performance:Application Size-Usability:Typography-Usability:Icons-Usability-Productivity-Accessibility-Internationalization-Internationalization:Bidirectional TextDesignErrorformatError typeE: Error
I: Information
W: WarningJSON format{"lintaosp":[{"file":"name","line":1,"type":"Error","details":"text"}]}Text formatlintaosp:{file}:{line}:{type}:{details}LicenseProject License can be foundhere.ReferenceAndroid linterrorformatgRPCprotocol-buffersreviewdog
Package: lintcheck
LintCheckPython IDLE extension to perform pylint analysis on an open fileInstallation (Without root permissions)Go to terminal and install withpip install lintcheck[user].Run commandidleuserextend; lintcheck. You should see the following
output:Config should be good! Config should be good!.Open IDLE, go toOptions->Configure IDLE->Extensions.
If everything went well, alongsideZzDummythere should be and
option calledlintcheck. This is where you can configure how
lintcheck works.Installation (Legacy, needs root permission)Go to terminal and install withpip install lintcheck.Run commandlintcheck. You will likely see a message sayinglintcheck not in system registered extensions!. Run the command
given to add lintcheck to your system's IDLE extension config file.Again run commandlintcheck. This time, you should see the following
output:Config should be good!.Open IDLE, go toOptions->Configure IDLE->Extensions.
If everything went well, alongsideZzDummythere should be and
option calledlintcheck. This is where you can configure how
lintcheck works.Information on optionsOptionignoreis a list of pylint messages,
separated by semicolons (;) that should be disabled using--disable.
Seepylint --helpfor more information.Optionjobsis the number of processes pylint should use when
checking your code, using--jobs. Seepylint --helpfor more information.Optionsearch_wrapis a boolian of whether or not searching for
the next# lintcheck:comment will wrap around or not, defaults to
False.
Package: lint_diffs
lint-diffslint-diffs is a simple command line tool for running a set of arbitrarty linters
on a set of 'unified diffs'.Errors on diff-lines will always be reported.   Errors on non-diff lines can also
be reported, depending on severity.First you need some diffs, then you pipe it to lint-diffs:git diff -U0 origin/master | lint-diffs... or in mercurial:hg outgoing -p | lint-diffsdefault linter configuration is on for pylint (.py), rubocop (.rb), and
clang (.cpp, .hpp)flake8, eslint and other linters need to be enabled (see below) explicitly.Configurationlint-diffswill read a config files from~/.config/lint-diffsand/or./.lint-diffs.Example:[pylint]always_report=E.*[flake8]extensions=.py[rubocop]extensions=.rbalways_report=(E.*|W.*)[eslint]extensions=.js[shellcheck]extensions=.shIn this example, a flake8 and pylint are run on every diff file ending in.py.
Additionally, ruby, eslint and shell script linters have been enabled.   The
ruby linter has been modified to always report warnings, on any changed file,
not just changed lines.To add new lintersThe linter has to report to stdoutThe linter has to have a regex that produces a full file path, a line number
and an error classThe line numbers and file paths have to match diff target file pathsTo enable or disable linters change the 'extensions' config.GoalsRuns with good defaults for many peopleShould be easy to modify the config for any linterShould be easy to use with any vcsDevelopmentThis project usesFlitto build its
packages. That might answer your question in case you are wondering why there
is nosetup.pyhere.
Package: lint-django-migrations
Lint Django migrationsInstallpipinstalllint_django_migrationsHow to useInstall the app in settings.pyINSTALLED_APPS=[# ..."lint_django_migrations",]Check your migrationspythonmanage.pylintmigrationsThis will return an error if any of the migrations are backwards incompatible.Fix errors
If there is an error, you have 2 options. Fix the migration or tell the linter that
the migration is not backwards incompatible. If you feel the migration is ok, run the command
again with the--interactiveflagpythonmanage.pylintmigrations--interactiveSetup on existing code baseIf you would like to setup the linter on the existing codebase, it can be tedious to mark
every applied migration as valid. For that purpose, you can snapshot the current state and
just run the linter on future migrationspythonmanage.pylintmigrations--force-update## All API optionsRun the linter in CIIf you want to run the linter, but not update the state use the following commandpythonmanage.pylintmigrations--check-only
Package: lintersmagic
Linters magicMagic function for pycodestyle module in Jupyter-Lab or Databricks notebooks.Current version: 0.1.6Versions of dependencies:python: 3.8pycodestyle: 2.8.0ipython: 8.1.1Note that we've tested it only on Databricks notebooksInstallationpip install lintersmagicUsageEnable the magic function by using the lintersmagic module in a cell%load_ext lintersmagicTo check a cell once:use the function as first line in your cell to check compliance withpycodestyleas such:%%pycodestyleTo auto check each cell:If you want this compliance checking turned on by default for each cell then run this magic line function in an empty cell:%pycodestyle_onYou only need to call this once (observe the single%).To turn off the auto-checking for each cell use:%pycodestyle_offConfig options for%pycodestyle_on(version >= 0.5)The option--ignoreor-iwill add the the named error(s) to the ignore listExample to ignore the errorsE225andE265:%pycodestyle_on --ignore E225,E265Remember toavoidspaces between declaring multiple errors.With the option--max_line_lengthor-mthe max-line-length can be customised.Example to set the line length to119characters instead of the default79:%pycodestyle_on --max_line_length 119The options can be combined as well.See notebooks in notebook directory for example use cases, as such:Pycodestyle (notebook)ContributionDependencies and packageHandled by Poetry (documentation)To get a new package:poetry buildTo install the dependencies:poetry installTo publish a new version:poetry publishTestspoetry run ipython tests/*.pyUseful linksThis project adds a magic function in Ipython. Here is the documentation:Built-in magic commandsThis project uses a callback with magic functions. Here is the documentation:IPython Events
Package: lintilla
lintillaShort blurb about what your product does.One to two paragraph statement about your product and what it does.InstallationOS X & Linux:pip3installlintillaWindows:pipinstalllintillaUsage exampleA few motivating and useful examples of how your product can be used. Spice this up with code blocks and potentially more screenshots.For more examples and usage, please refer to theWiki.Development setupDescribe how to install all development dependencies and how to run an automated test-suite of some kind. Potentially do this for multiple platforms.pipinstall--editablelintillaDocumentationRead the DocsExample UsageCreditsChangelogAPI ReferenceWikiMetaStephen R A King :sking.github@gmail.comDistributed under the MIT license. Seefor more information.Created with Cookiecutter template:cc_templateversion 1.2.1
Package: lintipy
lintipyAWS Lambda handlers for GitHub events wrapped in SNS messages.How it worksThe services is designed followingevent-driven architecture.
It is solely based upon AWS services. Namely AWS Lambda as event consumers and emitters as well as consumers and AWS SNS as channels.The exchange of events between AWS and GitHub is done usingCRUDHTTP methods. Events coming from GitHub are transferred to SNS using a small API Gateway service calledgithub-webhook-lambda. This part is not displayed in the sequence diagram above. Essentially each event coming from GitHub forwarded to a SNS. The topic of the SNS event is the same as the GitHub event type.Note that the check suite does not interact directly with the check runs nor via SNS. We rely on GitHub to trigger the correct events. This means that initial running of a check or rerunning it using the GitHub interface are treated identically.UsagefromlintipyimportCheckRunhandle=CheckRun.as_handler('PEP8','pycodestyle','.')See also:This package is used onFussyFox
Package: lintjenkins
lintjenkinslintjenkins 是干什么的? 这里举一个使用场景的例子. 我又一个django项目需要使用jenkins进行持续代码检查, 需要做的操作是:在jenkins上创建一个job, 配置job 和violations等信息.在配置job时，添加svn代码时,需要输入账号和密码进行验证查看检查结果当需要统计历史结果时, 只能手动去看一次次检查结果.lintjenkins 就是将上述场景操作封装为接口,便于二次开发.Free software: MIT licenseDocumentation:https://lintjenkins.readthedocs.io.Require目标机器装有jenkins+violations被检查的python代码所在目录符合包的形式,如:__init__.pyrequirements.txtpylint.cfgpylint配置文件也需要修改.没有配置可以使用`pylint –generate-rcfile > pylint.cfg`生成配置.将`output-format`项的值改为`parseable`init-hook`添加’import sys; sys.path.append(“/var/lib/jenkins/workspace/xxx”)’,`xxx`为jenkins job名. 否则会出现`W0403 Relative import ‘xxxx’警告ExampleIn[2]:fromlintjenkinsimportLintJenkinsIn[3]:lint_jenkins=LintJenkins('http://x.x.x.x:8080',username='username',password='password')In[4]:lint_jenkins.add_job(svn='svn',username='username',password='password',job_name='aliyun')In[7]:lint_jenkins.get_build_numbers('aliyun')Out[7]:[2,1]In[8]:lint_jenkins.get_build_info('aliyun',2)Out[8]:{"violation_info":{"violation_num":2027,"violation_file_num":80},"commits":[{"msg":"svn提交信息","paths":[{"editType":"add","file":"新增的文件"},{"editType":"edit","file":"编辑的文件"}],"revision":18830,"datetime":"2017-06-12 09:44:38","author":"huzhongzhong"}],"datetime":"2017-06-12 09:55:13","result_url":'http://x.x.x.x:8080/job/job_name/7/violations/'"result":"UNSTABLE","duration":49,"revisions":[{"module":"svn地址","revision":18830}]}字段说明:对应的在jenkins上的表现是:注意Credentials Plugin`使用的是版本`2.1.16如果报错`403 no valid crumb was included in the request, 简单可以这样处理:`setup jenkins’s “global security settings”: Uncheck “Prevent Cross Site Request Forgery exploits”CreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.History0.1.0 (2017-06-11)First release on PyPI.
Package: lintmon
lintmonA tool for monitoring for lint errors. Provides a configurable way to specify checks to run on code in a given directory when it changes on disk, run those checks in the background and provide a fast way to display the outcome of the latest checks with a concise format suitable for embedding in your prompt.It is designed for lint errors because these are quick to run and affect single files at a time, so in general they can be checked in the background with relatively low system impact, but in principle you could use it to trigger any sort of validation check, such as running unit tests.MotivationThe two main ways of avoiding pushing lint errors to a repo it seemed to me were:lint on save in your IDEadd git hooks on push to check for / fix lint errorsI didn't like either of those, because in both cases they happen synchronously while you are doing something and can cause disruptions. Also I push from the command line, so what I wanted was a warning at the point that I was going to push that was pre-calculated about errors.This is that.ConfigureInstall lintmon usingpipin your virtualenv (or wherever you install packages for use with your codebase):pip install lintmonAdd a file like the lintmon.yaml file in this codebase to the root directory of your codebase. It tells lintmon what checks to do on files. It aims to be very configurable.Add the following to your prompt in your.bashrcor.zshrc:PS1='$([[ -e lintmon.yaml ]] && which lintmon-status-prompt >/dev/null && lintmon-status-prompt)'$PS1That's it!lintmon-status-promptwill startlintmondautomatically in the background when it is run, and from now on you should get a "badge" in your prompt when there are lint errors in your directory, which will be updated when you modify files.Commandslintmon-statusOutput status of lintmon along with all current errors from the linters.lintmon-stop,lintmon-startTell lintmon to stop (and not restart automatically) or start again. Mostly useful for debugging lintmon. This will display anSbadge in your prompt to tell you it is stopped.lintmon-run-allRun all linters on all appropriate files in your project, thus "hydrating" lintmon's state if it hasn't been running for a while and changes have been made.lintmondRun the daemon in the shell (again mainly useful for debugging).Directory structurelintmon adds a.lintmondirectory to your project directory where it stores all its state about what current errors there are, lintmon's pid etc. You will probably want to add this to your .gitignore.
Package: lint-po
lint-poA simple gettext .po linter to check for mangled variable names in translations.Featuresreads utf-8 encoded *.po filesskipsmsgid/msgstrpairs where either value is unsetcompares original/translation pairs for common interpolation markers:supports{name},{123},<123>,</123>,<123/>,%(name)sensures both messages use the same set of variables - no renames, no removals, no additionssupports Github Actions error reporting syntax (whenenv.GITHUB_ACTIONSis set)Example usage$lint-polocale/*.po

Differencebetweenmsgid="Hello {name}"andmsgstr="Bonjour {nom}":Missingfrommsgstr:{name}Unexpectedinmsgstr:{nom}atproblem.po:2TODOcatch nesting errors (<0><1></0></1>), reordering is fine but nesting still needs to make senseensure positional counts (3x %s vs 4x %s, etc.)build: autoincrement version for releasescheck headers, Language:should match the filenamemsgstr "{count, plural, one {依存関係} other {依存関係}}"is the one case when the thing in {} needs to change between msgid and msgstr
Package: lint-python
lint-python-actionTool that runs common linters on CERT Polska projects written in Python.IncludesGitHub Actionscustom action.Used linters and auto-formatters are:pip install -U isort==5.10.1 black==22.6.0 flake8==4.0.1 mypy==0.971Installation$pipinstalllint-pythonHow to configure lint-python?Provide configuration inpyproject.tomlfile.[tool.lint-python]lint-version="2"source="lint_python/"# Put your source directoryextra-requirements="types-requests"# Provide additional typing requirements if neededuse-mypy=false# Turn off any tool you don't want to useTools are opt-out, so if you don't use static typing in your project, you can turn off any tool from linting.If you use Github Actions, you can add it to any steps of the workflow e.g..github/workflows/test.ymlname:Test the codeon:push:branches:-masterpull_request:branches:-masterjobs:lint:runs-on:ubuntu-lateststeps:-uses:CERT-Polska/lint-python-action@v2with:source:karton/Tool can be configured viawithparameters, but they must be provided directly.
Don't use any expansion because lint-python tool parses the workflow file on its own.How to use it?$lint-pythonINFO:root:Linting with isortINFO:root:Linting with blackAll done! ✨ 🍰 ✨3 files left unchanged.INFO:root:Linting with flake8INFO:root:Linting with mypySuccess: no issues found in 3 source filesIf you want to only perform a check without modifying files, use--checkflag$lint-python--checkIf you have not installed packages and tools required for linting, use--installflag or--install-onlyflag if
you don't want to lint immediately after successful installation.$lint-python--installTry--helpfor more settings.Tips for linting your own projectIf you want to introduce these linters into your project, some tools need to be preconfigured to cooperate correctly.
Checkhttps://black.readthedocs.io/en/stable/guides/using_black_with_other_tools.htmlfor more information.Our recommended settings are:# in pyproject.toml file:[tool.isort]multi_line_output=3include_trailing_comma=trueforce_grid_wrap=0use_parentheses=trueensure_newline_before_comments=trueline_length=88# in .flake8, setup.cfg or tox.ini file:[flake8]max-line-length=88extend-ignore=E203, W503Read morehttps://black.readthedocs.io/en/stable/https://black.readthedocs.io/en/stable/guides/using_black_with_other_tools.htmlhttps://pycqa.github.io/isort/https://flake8.pycqa.org/en/latest/http://mypy-lang.org/
Package: lint-review
lint_reviewPlug in any linter for a code review!Features:Creates merge request comments according to linter commentsEasy to expand to any linter - just pass--custom-patternwith a regex capturing the important parts of the linter errors.Automatically resolves any comments that are no longer relevant.Usage:Create anaccess tokenwithapipremissionsPipe your linter intolint_reviewas part of your merge request CIMake a few mistakes (we all do)Fix the comments as they pop upFull interfaceusage:lint_review[-h][--linter{flake8,mypy}]--reviewer{dry,gitlab}[--custom_patternCUSTOM_PATTERN][--tokenTOKEN][--projectPROJECT][--merge_requestMERGE_REQUEST]optionalarguments:-h,--helpshowthishelpmessageandexit--linter{flake8,mypy}Nameofthelintertouse--reviewer{dry,gitlab}Theserviceusedtoreviewthecode--custom_patternCUSTOM_PATTERNAcustomregexpatterntocapturecomments.Thepatternmusthavethenamedcapturegroups:{'line','message','path'}andoptionallycol

gitlab:--tokenTOKENAPItokenforgitlab,Isrequiredforgitlabusage--projectPROJECTProjectIDofthemergerequest,defaultstoenviromentvariablesetbypipeline.--merge_requestMERGE_REQUESTInternalIDofthemergerequest,defaultstoenviromentvariablesetbypipeline.
Package: lintrunner-adapters
lintrunner-adaptersAdapters and tools forlintrunner.lintrunner-adapterscurrently supports popular Python / Rust / C++ linters and formatters likeflake8,pylint,mypy,black,ruff(with auto-fix support),rustfmt,clippy,clang-formatand many more - and the list is growing. Contribution is welcome!To see the list of supported linters and formatters, runlintrunner_adapters run.Installpipinstalllintrunner-adaptersUsageUsage: python -m lintrunner_adapters [OPTIONS] COMMAND [ARGS]...

Options:
  --help  Show this message and exit.

Commands:
  run       Run an adapter.
  to-sarif  Convert the output of lintrunner json (INPUT) to SARIF (OUTPUT).Uselintrunner_adapters runto see a list of adapters available.GitHub actionhttps://github.com/justinchuby/lintrunner-actionHow toUselintrunner_adapterswithlintrunnerin your projectRefer to the.lintrunner.tomlconfig file in this repo and example configs for each adapter underexamples/adapters.Write lint config in.lintrunner.tomlSeehttps://docs.rs/lintrunner/latest/lintrunner/lint_config/struct.LintConfig.html.Create a new adapterUselintrunner_adapters/adapters/pylint_linter.pyas an example.Run lintrunner in CI and get Github code scanning messages in your PRsOption 1Use a GitHub Action:lintrunner-actionOption 2Run it directly in the workflow. See.github/workflows/ci.yml.