{"id":15499570,"url":"https://github.com/mitar/pychecker","last_synced_at":"2025-04-09T20:49:08.701Z","repository":{"id":9658442,"uuid":"11596759","full_name":"mitar/pychecker","owner":"mitar","description":"PyChecker git fork.","archived":false,"fork":false,"pushed_at":"2013-07-23T04:43:09.000Z","size":2376,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-10-19T15:18:54.093Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://pychecker.sourceforge.net/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"KanbanSolutions/pysolr","license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mitar.png","metadata":{"files":{"readme":"README","changelog":"ChangeLog","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-07-23T01:42:29.000Z","updated_at":"2017-01-02T14:25:26.000Z","dependencies_parsed_at":"2022-09-10T03:42:14.360Z","dependency_job_id":null,"html_url":"https://github.com/mitar/pychecker","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mitar%2Fpychecker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mitar%2Fpychecker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mitar%2Fpychecker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mitar%2Fpychecker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mitar","download_url":"https://codeload.github.com/mitar/pychecker/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248111940,"owners_count":21049576,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-02T08:53:41.911Z","updated_at":"2025-04-09T20:49:08.674Z","avatar_url":"https://github.com/mitar.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"PyChecker is a tool for finding bugs in python source code.\nIt finds problems that are typically caught by a compiler for less\ndynamic languages, like C and C++.  It is similar to lint.\nBecause of the dynamic nature of python, some warnings\nmay be incorrect; however, spurious warnings should be fairly infrequent.\n\nPyChecker works in a combination of ways.  First, it imports each\nmodule.  If there is an import error, the module cannot be processed.\nThe import provides some basic information about the module.  The code\nfor each function, class, and method is checked for possible problems.\n\nTypes of problems that can be found include:\n\n  * No global found (e.g., using a module without importing it)\n  * Passing the wrong number of parameters to functions/methods/constructors\n  * Passing the wrong number of parameters to builtin functions \u0026 methods\n  * Using format strings that don't match arguments\n  * Using class methods and attributes that don't exist\n  * Changing signature when overriding a method\n  * Redefining a function/class/method in the same scope\n  * Using a variable before setting it\n  * self not the first parameter to a method\n  * Unused globals and locals (module or variable)\n  * Unused function/method arguments (can ignore self)\n  * No doc strings in modules, classes, functions, and methods\n\nUsing PyChecker\n---------------\nTo use PyChecker, pass the python source files you want to check\non the command line:\n\n\tpychecker file1.py file2.py ...\n\nNote:  On Windows, use pychecker.bat.  You may also need to add\npython/scripts to your PATH.\n\npychecker and pychecker.bat will only exist if pychecker has been\ninstalled.  To install, do:  python setup.py install\n\nNote:  If you haven't installed pychecker, it can be run by doing:\npython pychecker/checker.py\n\nAn alternate way to use PyChecker is to import it in your code.\nSee 'Importing PyChecker' below for more details.\n\nIf there are import dependencies in your source files, you should\nimport those files first on the command line in order to get as many\nfiles checked as possible.\n\nPyChecker works with Python 2.0 through 2.7.\nSome features don't work on earlier versions of Python.\nPyChecker is tested with Python 2.2 through 2.7 using buildbot.\n\nYou can use the test files as examples:\n\n\tpychecker [options] test_input/*.py\n\nIf you want to change the default behaviour, you can pass command line options\nor define a .pycheckrc file.  For an example, look at pycheckrc.\n\nTo show the available options, do:\n\n\tpychecker -h\n\nSome of the most common options are:\n\n      --only         only warn about files passed on the command line [off]\n  -#, --limit        the maximum number of warnings to be displayed [10]\n  -s, --shadowbuiltin check if a variable shadows a builtin [on]\n  -q, --stdlib       ignore warnings from files under standard library [off]\n  -T, --argsused     unused method/function arguments [on]\n\nThere is a simple GUI which is not maintained much.  It is good\nfor showing all the options and also allows you to run pychecker.\nTo run options, you will need to start it manually:\n\n\tpython pychecker/options.py\n\nIf you want to suppress warnings on a module/function/class/method,\nyou can define a suppressions dictionary in .pycheckrc.\nExamples of keys are:  'module', 'module.function',\n\t\t       'module.class', 'module.class.method', etc.\n\nYou can also define suppressions in your code by doing:\n\n\t__pychecker__ = 'no-namedargs maxreturns=0 unusednames=foo,bar'\n\nThe format for __pychecker__ values and values in the suppressions dictionary\nare the same.  Dashes (--) are optional when preceding long option names.\n\nImporting PyChecker\n-------------------\nYou can import PyChecker in your code's main module, by doing:\n\n        import pychecker.checker\n\nThis will allow each module imported after PyChecker to be checked \n(other than the main module).  NOTE:  Modules imported before PyChecker\nwill not be checked.  Warnings will be displayed on stdout \n(ie, PyChecker uses print).\n\nSince you can't pass command line parameters, you can do:\n\n        os.environ['PYCHECKER'] = 'command line options here'\n\nThis is equivalent of setting PYCHECKER in the shell environment:\n\n        PYCHECKER='no-namedargs maxreturns=0' /path/to/your/program\n\nIf you want to disable the warnings (and processing done by PyChecker), \nprior to importing PyChecker, do:\n\n        os.environ['PYCHECKER_DISABLED'] = 1\n\nThis is equivalent of setting PYCHECKER_DISABLED in the shell environment:\n\n        PYCHECKER_DISABLED=1 /path/to/your/program\n\nInternal Errors\n---------------\nIf you find a bug in PyChecker, meaning you see something like:\n\n\tpychecker myfile.py\n\n\tmyfile.py:13 INTERNAL ERROR -- STOPPED PROCESSING FUNCTION --\n        Traceback (most recent call last):\n          File \"./pychecker/warn.py\", line 364, in _checkFunction\n            stack, oparg, lastLineNum)\n          File \"./pychecker/warn.py\", line 195, in _handleFunctionCall\n            kwArgs.append(stack[i].data)\n        IndexError: list index out of range\n\nPlease post a bug in the SourceForge Tracker\n(https://sourceforge.net/tracker/?atid=382217\u0026group_id=24686\u0026func=browse)\nor send mail indicating the version of PyChecker, *your source file*\nwhich broke PyChecker (myfile.py in the example above), and the traceback.\nIt is very helpful to provide a simple test case to demonstrate the problem.\nIt helps to have the entire file and all the dependencies if you cannot\nproduce a simple test case.  But if you can't provide a test case nor\nthe file(s), I may be able to figure out the problem with just the line\nwhich broke PyChecker (myfile.py:13 in the example above).\n\nGood Luck!  As always, feedback is greatly appreciated.\n\nBuildbot\n--------\n\nPychecker is tested on each commit using Buildbot.  See\nhttp://build.fluendo.com:8200/\n\nIRC\n---\n\nFeel free to ask questions on #pychecker on irc.freenode.org\nOur friendly buildbot is there too.\n\nProjects using PyChecker\n------------------------\n\nPychecker is regularly run on the following projects:\n\n * moap\n * morituri\n * savon\n * flumotion\n\nBefore each release these projects get checked to test that PyChecker works.\n\nIf your project uses PyChecker too, let us know so we can add it here and\nto our release checklist.\n\nNeal\npychecker-list@lists.sourceforge.net\n\nPyChecker can be found on SourceForge at:\n\thttp://pychecker.sourceforge.net/\n\thttp://sourceforge.net/projects/pychecker\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmitar%2Fpychecker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmitar%2Fpychecker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmitar%2Fpychecker/lists"}