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

Pre-commit mdformat hook conflict #464

Closed
1 task done
fyliu opened this issue Feb 6, 2025 · 0 comments · Fixed by #465 · May be fixed by #471
Closed
1 task done

Pre-commit mdformat hook conflict #464

fyliu opened this issue Feb 6, 2025 · 0 comments · Fixed by #465 · May be fixed by #471
Assignees
Labels
complexity: small Small changes with all steps laid out in detail; new member can complete in <1.5 hours feature: build good first issue Good for newcomers role: dev s: PD team stakeholder: People Depot Team size: 0.25pt Can be done in 1.5 hours or less

Comments

@fyliu
Copy link
Member

fyliu commented Feb 6, 2025

Overview

The automated pre-commit checks in GitHub shows the code is broken. This is because pre-commit.ci is running a newer version of mdformat-mkdocs than our developer local systems, which is why we don't see the error.

In the newer version, mdformat-mkdocs and mdformat-admon are both trying to format admonitions, and we should drop mdformat-admin since mdformat-mkdocs does it better.

Action Items

  • update the .pre-commit-config.yaml to remove mdformat-admon and set a minimum version on mdformat-mkdocs

Resources/Instructions

  • The error: Recent commits to main where the ones in Feb 3 have red x marks for failing pre-commit

    Image

  • Why don't developer see the error locally? Individual developers may not see this error if they have an older version of mdformat-mkdocs hook installed. The way to update is pre-commit clean followed by pre-commit run. Setting the minimum version will cause the developer pre-commit install to update to the new version.

  • Why choose mdformat-mkdocs over mdformat-admon? from mdformat-mkdocs readme

    Image

@fyliu fyliu added feature: build good first issue Good for newcomers role: dev s: PD team stakeholder: People Depot Team size: 0.25pt Can be done in 1.5 hours or less labels Feb 6, 2025
@fyliu fyliu added this to the 04. Project Setup milestone Feb 6, 2025
@fyliu fyliu self-assigned this Feb 6, 2025
@github-project-automation github-project-automation bot moved this to 🆕New Issue Review in P: PD: Project Board Feb 6, 2025
@fyliu fyliu moved this from 🆕New Issue Review to 🏗In progress-actively working in P: PD: Project Board Feb 6, 2025
@fyliu fyliu changed the title Pre-commit mdformat broken Pre-commit mdformat hook conflict Feb 6, 2025
@shmonks shmonks added the complexity: small Small changes with all steps laid out in detail; new member can complete in <1.5 hours label Feb 7, 2025
@github-project-automation github-project-automation bot moved this from 🏗In progress-actively working to ✅Done in P: PD: Project Board Feb 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
complexity: small Small changes with all steps laid out in detail; new member can complete in <1.5 hours feature: build good first issue Good for newcomers role: dev s: PD team stakeholder: People Depot Team size: 0.25pt Can be done in 1.5 hours or less
Projects
Status: ✅Done
2 participants