Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(pre-commit): support python additional_dependencies #33417

Merged
merged 1 commit into from
Jan 8, 2025

Conversation

trim21
Copy link
Contributor

@trim21 trim21 commented Jan 5, 2025

partial support for #20780

Changes

pre-commit hooks additional_dependencies are dynamic to many language, so we only support it if it's defined as language: python.

Normally hooks from repo doesn't need this, but add it also doesn't break anything and make our work must more easy so we do not need to do a extra http request and parse hooks from arbitrary repo in extracter.

support this kind of pre-commit config:

  - repo: https://github.com/psf/black
    rev: 19.3b0
    hooks:
      - id: black
        language: python
        additional_dependencies:
          - "request==1.1.1"

and this won't work:

  - repo: https://github.com/psf/black
    rev: 19.3b0
    hooks:
      - id: black
        additional_dependencies:
          - "request==1.1.1"

Context

Documentation (please check one with an [x])

  • I have updated the documentation, or
  • No documentation update is required

How I've tested my work (please select one)

I have verified these changes via:

  • Code inspection only, or
  • Newly added/modified unit tests, or
  • No unit tests but ran on a real repository, or
  • Both unit tests + ran on a real repository

trim21/bencode-py@ad08e6e
trim21/bencode-py@47abeed

@trim21 trim21 changed the title feat: support pre-commit local python hooks additional_dependencies feat(pre-commit): support python additional_dependencies Jan 5, 2025
@trim21 trim21 marked this pull request as ready for review January 5, 2025 22:52
@trim21 trim21 force-pushed the add branch 2 times, most recently from 3b0bfa4 to 6db8047 Compare January 5, 2025 23:07
@rarkins rarkins added this pull request to the merge queue Jan 8, 2025
Merged via the queue into renovatebot:main with commit 59455c0 Jan 8, 2025
39 checks passed
@trim21 trim21 deleted the add branch January 8, 2025 12:40
@renovate-release
Copy link
Collaborator

🎉 This PR is included in version 39.95.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants