{"id":18438667,"url":"https://github.com/seapagan/poetry-plugin-check-yanked","last_synced_at":"2025-04-07T21:31:58.027Z","repository":{"id":243813562,"uuid":"813517806","full_name":"seapagan/poetry-plugin-check-yanked","owner":"seapagan","description":"A Poetry plugin to check for yanked packages in the poetry.lock file.","archived":false,"fork":false,"pushed_at":"2025-03-31T17:01:52.000Z","size":910,"stargazers_count":2,"open_issues_count":8,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-05T13:53:23.358Z","etag":null,"topics":["dependency-management","github-action","lockfile","lockfile-parser","lockfile-validation","package-management","poetry","poetry-plugin","pypi","python","yanked"],"latest_commit_sha":null,"homepage":"https://seapagan.github.io/poetry-plugin-check-yanked/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/seapagan.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.txt","code_of_conduct":"CODE_OF_CONDUCT.md","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":"2024-06-11T08:38:18.000Z","updated_at":"2025-01-16T11:01:00.000Z","dependencies_parsed_at":"2025-02-17T18:25:48.501Z","dependency_job_id":"34329467-3e81-4bba-a160-0b4a36363a82","html_url":"https://github.com/seapagan/poetry-plugin-check-yanked","commit_stats":null,"previous_names":["seapagan/poetry-plugin-yanked-check","seapagan/poetry-plugin-check-yanked"],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seapagan%2Fpoetry-plugin-check-yanked","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seapagan%2Fpoetry-plugin-check-yanked/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seapagan%2Fpoetry-plugin-check-yanked/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seapagan%2Fpoetry-plugin-check-yanked/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/seapagan","download_url":"https://codeload.github.com/seapagan/poetry-plugin-check-yanked/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247345823,"owners_count":20924101,"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":["dependency-management","github-action","lockfile","lockfile-parser","lockfile-validation","package-management","poetry","poetry-plugin","pypi","python","yanked"],"created_at":"2024-11-06T06:21:04.125Z","updated_at":"2025-04-07T21:31:57.505Z","avatar_url":"https://github.com/seapagan.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Poetry Plugin : Check for Yanked Packages \u003c!-- omit in toc --\u003e\n\n[![PyPI version](https://badge.fury.io/py/poetry-plugin-check-yanked.svg)](https://badge.fury.io/py/poetry-plugin-check-yanked)\n![PyPI - License](https://img.shields.io/pypi/l/poetry-plugin-check-yanked)\n[![Codacy Badge](https://app.codacy.com/project/badge/Grade/a2d631f85efd43028733ff638d9c69ea)](https://app.codacy.com/gh/seapagan/poetry-plugin-check-yanked/dashboard?utm_source=gh\u0026utm_medium=referral\u0026utm_content=\u0026utm_campaign=Badge_grade)\n\nThis is a plugin for the [Poetry](https://python-poetry.org/) dependency\nmanagement tool that adds a new command to check if any of the dependencies in\nthe `pyproject.toml` file have been yanked.\n\nThis plugin was written to learn how to write a Poetry plugin and to scratch an\nitch I had for a tool like this. I have more [ideas](TODO.md) for features and\nimprovements, and I welcome any [contributions](CONTRIBUTING.md) or suggestions.\n\n- [Installation](#installation)\n- [Usage](#usage)\n  - [Available options](#available-options)\n  - [Configuration](#configuration)\n- [Use as a GitHub Action](#use-as-a-github-action)\n- [Development setup and Contributing](#development-setup-and-contributing)\n- [License](#license)\n- [Credits](#credits)\n\n## Installation\n\nThe easiest way to install this Poetry plugin is via the `self add` command of\nPoetry.\n\n```bash\npoetry self add poetry-plugin-check-yanked\n```\n\nIf you used `pipx` to install Poetry you can add the plugin via the `pipx\ninject` command.\n\n```bash\npipx inject poetry poetry-plugin-check-yanked\n```\n\nOtherwise, if you used `pip` to install Poetry you can add the plugin packages\nvia the `pip install` command.\n\n```bash\npip install poetry-plugin-check-yanked\n```\n\n## Usage\n\nThe plugin adds a new command to Poetry, `check-yanked`, which can be used to\ncheck if any of the dependencies in the `pyproject.toml` file have been yanked\nfrom PyPI by their maintainers. There is usually a pretty good reason for a\npackage to be yanked, so it's a good idea to check for yanked packages in your\nproject.\n\nWhen you check for yanked packages, the plugin will download the latest\nmetadata for each package in the `poetry.lock` file and check if any of them are\nyanked. If any are found, the command will return a non-zero exit code and list\nthe yanked packages along with the reason for the yank. Once a specific package\nverison has been checked, it will be cached for a period of time (default 1 day)\nto minimize the number of requests to PyPI (and speed up future runs).\n\n\u003e [!NOTE]\n\u003e This plugin uses the `poetry.lock` file to determine the exact versions of\n\u003e the dependencies to check, so it will also check for any yanked dependencies\n\u003e of the dependencies you have specified in the `pyproject.toml` file.\n\n```bash\npoetry check-yanked\n```\n\nThe command will return a non-zero exit code if any dependencies have been\nyanked along with a list of the yanked dependencies and the reason for the yank.\n\n### Available options\n\n- `--full` - Check each project dependency package again, even if it is already\n  in the cache.\n- `--refresh` - Refesh the entire cache and exit, no not check for yanked\n  packages.\n- `--no-progress` - Don't show the progress bar when checking for yanked\n  packages, useful for CI/CD environments.\n- `--quiet` - Don't show any output, just return a non-zero exit code if any\n  dependencies are yanked.\n- `--verbose` - Show more detailed output, including each dependency and it's\n  yank status. This disables the progress bar.\n\n### Configuration\n\nAt this time, the only configuration option is the cache timeout, which is set\nto 1 day by default. This can be changed by adding a `[tool.check-yanked]`\nsection to the `pyproject.toml` file with a `cache_expiry` key. This value is\nin seconds. and the default is 86400 (1 day). Future versions of the plugin will\noffer pre-defined cache times (e.g. 1 hour, 1 day, 1 week, etc.) as well as the\nability to disable the cache entirely.\n\n```toml\n[tool.check-yanked]\ncache_expiry = 3600 # 1 hour\n```\n\n## Use as a GitHub Action\n\nThis plugin can be used as a GitHub Action to check for yanked packages\nautomatically as part of your CI. Here is an example workflow:\n\n```yaml\nname: Check for Yanked Packages\n\non: [push, pull_request]\n\njobs:\n  check-yanked:\n    runs-on: ubuntu-latest\n\n    steps:\n      - name: Run poetry check-yanked\n        uses: seapagan/check-yanked-packages@v1\n```\n\nThere are two optional inputs that can be used to configure the action:\n\n- `path` - The path to the directory containing the `poetry.lock` file. This\n  defaults to the root of the repository.\n- `python-version` - The version of Python to use when running the action. This\n  defaults to the latest version of Python 3.x available on the runner.\n  - If you are using the `actions/setup-python` action, this will be **ignored**,\n  and the version of Python installed by that will be used instead.\n\nThese can be set in the workflow file like so:\n\n```yaml\n- name: Run poetry check-yanked\n  uses: seapagan/check-yanked-packages@v1\n  with:\n    python-version: '3.10'\n    path: 'path/to/directory'\n```\n\nSee the\n[check-yanked-packages](https://github.com/seapagan/check-yanked-packages)\naction for more information on using this plugin as a GitHub Action. The\n`cache-expiry` option is not available when using the action, as the cache is\nnot persisted between runs.\n\n## Development setup and Contributing\n\nCheck [CONTRIBUTING.md](CONTRIBUTING.md) for full instructions on how to set up\nthe project for development, and [CODE_OF_CONDUCT.md](CODE_OF_CONDUCT.md) for\nthe project code of conduct.\n\n## License\n\nThis project is released under the terms of the MIT license.\n\n## Credits\n\nThe original Python boilerplate for this package was created using\n[Pymaker](https://github.com/seapagan/py-maker) by [Grant\nRamsay](https://github.com/seapagan)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseapagan%2Fpoetry-plugin-check-yanked","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fseapagan%2Fpoetry-plugin-check-yanked","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseapagan%2Fpoetry-plugin-check-yanked/lists"}