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

fix(misc): format:check not checking all affected files #9152

Merged
merged 1 commit into from Mar 2, 2022
Merged

fix(misc): format:check not checking all affected files #9152

merged 1 commit into from Mar 2, 2022

Conversation

miluoshi
Copy link
Contributor

@miluoshi miluoshi commented Mar 1, 2022

While running format:write and format:check commands, a list of affected files is split to chunks of 50 files, that was originally meant as compatibility optimization for Windows users (see #2362).
This causes early exits in cases if there are also incorrectly formatted files in both 1st and following chunks.

Current Behavior

  • have >50 files affected by your changes
  • have at least 1 file within 1st chunk of 50 files incorrectly formatted AND at least 1 file in the 2nd chunk
  • nx format:check will exit after checking 1st chunk and will not print incorrectly formatted files in the following chunks
  • nx format:write works correctly and writes all affected files

Expected Behavior

nx format:check should check and print incorrectly formatted files among all affected files, not only first incorrect chunk.

Related Issue(s)

Fixes #9151

@nx-cloud
Copy link

nx-cloud bot commented Mar 1, 2022

☁️ Nx Cloud Report

CI ran the following commands for commit 630f28d. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this branch


✅ Successfully ran 7 targets

Sent with 💌 from NxCloud.

@vercel
Copy link

vercel bot commented Mar 1, 2022

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/nrwl/nx-dev/95urwMK7PTuEtckA8CkeSCSPmPyF
✅ Preview: Canceled

[Deployment for 630f28d canceled]

While running format:write and format:check commands, a list of affected files is split to chunks of 50 files, that was originally meant as compatibility optimization for Windows users (see #2362).
This causes early exits in cases if there are also incorrectly formatted files in both 1st and following chunks.

fixes #9151
@miluoshi miluoshi marked this pull request as ready for review March 1, 2022 16:36
@AgentEnder AgentEnder changed the title fix(misc): fix format:check not checking all affected files fix(misc): format:check not checking all affected files Mar 2, 2022
@AgentEnder AgentEnder merged commit ea33428 into nrwl:master Mar 2, 2022
@github-actions
Copy link

This pull request has already been merged/closed. If you experience issues related to these changes, please open a new issue referencing this pull request.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 19, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

format:check command doesn't check all files if check fails within first 50 affected files
2 participants