{"id":16876243,"url":"https://github.com/coolcat467/idlemypyextension","last_synced_at":"2026-04-11T07:08:38.981Z","repository":{"id":63878463,"uuid":"571426279","full_name":"CoolCat467/idlemypyextension","owner":"CoolCat467","description":"Python IDLE extension to preform mypy analysis on an open file","archived":false,"fork":false,"pushed_at":"2025-04-01T15:43:01.000Z","size":490,"stargazers_count":2,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-01T16:50:44.365Z","etag":null,"topics":["analysis","coolcat467","daemon","extension","hacktoberfest","idle","mypy","python","python-idle","python3","tkinter","tkinter-gui","tkinter-python"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/idlemypyextension","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CoolCat467.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-11-28T05:14:41.000Z","updated_at":"2025-04-01T15:43:05.000Z","dependencies_parsed_at":"2023-01-30T16:30:29.839Z","dependency_job_id":"29947a12-07b0-49c1-a033-393d83d1d57e","html_url":"https://github.com/CoolCat467/idlemypyextension","commit_stats":{"total_commits":5,"total_committers":1,"mean_commits":5.0,"dds":0.0,"last_synced_commit":"d83285a1897c885d3603682a4a8273fc731b9cec"},"previous_names":[],"tags_count":17,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CoolCat467%2Fidlemypyextension","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CoolCat467%2Fidlemypyextension/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CoolCat467%2Fidlemypyextension/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CoolCat467%2Fidlemypyextension/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CoolCat467","download_url":"https://codeload.github.com/CoolCat467/idlemypyextension/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248384076,"owners_count":21094669,"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":["analysis","coolcat467","daemon","extension","hacktoberfest","idle","mypy","python","python-idle","python3","tkinter","tkinter-gui","tkinter-python"],"created_at":"2024-10-13T15:38:45.727Z","updated_at":"2026-04-11T07:08:38.976Z","avatar_url":"https://github.com/CoolCat467.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# IdleMypyExtension\nPython IDLE extension to perform mypy analysis on an open file\n\n[![CI](https://github.com/CoolCat467/idlemypyextension/actions/workflows/ci.yml/badge.svg)](https://github.com/CoolCat467/idlemypyextension/actions/workflows/ci.yml)\n\u003c!-- BADGIE TIME --\u003e\n\n[![pre-commit.ci status](https://results.pre-commit.ci/badge/github/CoolCat467/idlemypyextension/main.svg)](https://results.pre-commit.ci/latest/github/CoolCat467/idlemypyextension/main)\n[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit)](https://github.com/pre-commit/pre-commit)\n\n\u003c!-- END BADGIE TIME --\u003e\n\n## What does this extension do?\n- This IDLE extension hooks into the mypy daemon to type check the\ncurrently open file or provide a function signature suggestion for the\nnearest function to the top from the current input cursor location.\n\n- When type checking the currently open file with the \"Type Check File\"\ncommand, it will add comments to your code wherever mypy had something\nto say about about that line.\n\n- You can remove type comments added by this extension from the\ncurrently selected text with the \"Remove Type Comments\" command.\n\n- You can jump to the next comment this extension created in your file\nwith the \"Find Next Type Comment\" command.\n\n- You can add an inferred function signature to your file with the\n\"Suggest Signature\" command when you are close by a function definition.\n\n- In the right click menu, you can inspect the type of the object your\ncursor is currently selecting. In this case, it adds type info comments\nabout all of the objects you might be referring to. If you have a span\nof text selected, it will tell you about the type of only that span.\n\n- In the right click menu, you can go to the definition of the object\nyour cursor is currently selecting.\n\n- In the right click menu, you can view the attributes mypy knows about\nof the object your cursor is currently selecting.\n\nNote: On use, creates folder `mypy` within the idle user directory.\nOn Linux systems, this is usually `~/.idlerc/mypy`.\n\n## Installation (Without root permissions)\n1) Go to terminal and install with `pip install idlemypyextension[user]`.\n2) Run command `idleuserextend; idlemypyextension`. You should see the following\noutput: `Config should be good! Config should be good!`.\n3) Open IDLE, go to `Options` -\u003e `Configure IDLE` -\u003e `Extensions`.\nIf everything went well, alongside `ZzDummy` there should be and\noption called `idlemypyextension`. This is where you can configure how\nidlemypyextension works.\n\n## Installation (Legacy, needs root permission)\n1) Go to terminal and install with `pip install idlemypyextension`.\n2) Run command `idlemypyextension`. You will likely see a message saying\n`idlemypyextension not in system registered extensions!`. Run the command\ngiven to add idlemypyextension to your system's IDLE extension config file.\n3) Again run command `idlemypyextension`. This time, you should see the\nfollowing output: `Config should be good!`.\n4) Open IDLE, go to `Options` -\u003e `Configure IDLE` -\u003e `Extensions`.\nIf everything went well, alongside `ZzDummy` there should be and\noption called `idlemypyextension`. This is where you can configure how\nidlemypyextension works.\n\n\n## Information on options\n`action_max_sec` controls how long an action is allowed to take at most,\nin seconds. Default is \"None\".\n\nFor `daemon_flags`, see `mypy --help` for a list of valid flags.\nThis extension sets the following flags to be able to work properly:\n```\n    --hide-error-context\n    --no-color-output\n    --show-absolute-path\n    --no-error-summary\n    --soft-error-limit=-1\n    --show-traceback\n    --cache-dir=\"~/.idlerc/mypy\"\n```\n\nIf you add the `--show-column-numbers` flag to `daemon_flags`, when using the\n\"Type Check File\" command, it will add a helpful little `^` sign\nin a new line below the location of the mypy message that provided a column\nnumber, as long as that comment wouldn't break your file's indentation too much.\n\nIf you add the `--show-error-codes` flag to `daemon_flags`, when using the\n\"Type Check File\" command, when it puts mypy's comments in your code, it will\ntell you what type of error that comment is. For example, it would change the\nerror comment\n```python\n# types: error: Incompatible types in assignment (expression has type \"str\", variable has type \"int\")\n```\nto\n```python\n# types: assignment error: Incompatible types in assignment (expression has type \"str\", variable has type \"int\")\n```\n\n`search_wrap` toggles weather searching for next type comment will wrap\naround or not.\n\n`suggest_replace` toggles weather Suggest Signature will replace the\nexisting function definition or just add a comment with the suggested\ndefinition\n\n`timeout_mins` controls how long the mypy daemon will time out after,\nin minutes.\n\n`should_restart_always` toggles if the extension should restart dmypy\ndaemon before every run. May be helpful in some cases because of issues\nwith errors not being reported on subsequent runs, but this will slow\nthings down a lot.\n\n`force_base_ipc_request` toggles if the extension should force using\nmypy's provided inner process communication (IPC) module instead of\nreimplementing IPC messaging but asynchronously from scratch. Note, this\nis only effective on non-windows devices, because the way mypy does IPC\non windows is really complicated and doesn't have any benefits being\nreimplemented over just using `trio.wrap_file`.\n\n## Annotating files from mypy error logs\nI kept running into cases a lot where CI systems generate mypy error logs, and\nI needed to fix those errors with my local copy. If you copy all the mypy\nerrors into a file, say `error.txt`, you can have idlemypyextension annotate\nall of those files with a command like this:\n\n```bash\nidlemypyextension error.txt\n```\n\nwhich will open a blank IDLE window, hook into `idlemypyextension`, have it\nadd annotations to all files referenced in error log file, and then close\nthat temporary blank window, leaving all the files with errors still open.\n\nIf for some reason you need to run plain mypy instead of dmypy, you can do\n```bash\nmypy | idlemypyextension -\n```\n\n### Links\n* Source Code - https://github.com/CoolCat467/idlemypyextension.git\n* Issues      - https://github.com/CoolCat467/idlemypyextension/issues\n* Pypi        - https://pypi.org/project/idlemypyextension/\n\n### License\n-------\nCode and documentation are available according to the GNU General Public License v3.0 (see [LICENSE](https://github.com/CoolCat467/idlemypyextension/blob/HEAD/LICENSE)).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcoolcat467%2Fidlemypyextension","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcoolcat467%2Fidlemypyextension","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcoolcat467%2Fidlemypyextension/lists"}