TheAlgorithms / TheAlgorithms/Python

Should we add matchify to pre-commit

Open
#15,337 8 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Python
Stars
225k
Forks
51.1k
Avg merge
1d 23h
Merged PRs (30d)
156

Description

Feature description

@priya-sundaram-dev, please evaluate if we should add https://github.com/15r10nk/matchify to our codebase.

Python's match statement is powerful and we should encourage contributors to use it where it makes sense.

On Python 14t, please run uv tool install matchify && matchify data_structures, which should modify six files.

Do these changes look correct and useful? Do you recommend we add this tool to pre-commit?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Run uv tool install matchify && matchify data_structures on Python 14t as requested, then inspect the six modified files. Evaluate whether the transformations are correct and useful for this codebase and whether matchify belongs in pre-commit. Done means documenting the findings and making a clear recommendation.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.