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

nx format may error for too many files #511

Closed
FrozenPandaz opened this issue May 22, 2018 · 1 comment · Fixed by #727
Closed

nx format may error for too many files #511

FrozenPandaz opened this issue May 22, 2018 · 1 comment · Fixed by #727
Assignees

Comments

@FrozenPandaz
Copy link
Collaborator

Description

nx format --untracked may fail if there are a lot a lot of files since we concatenate them into a single command. This may exceed the limit for the size of a command/ input which I think is dictated by the operating system.

Originally discovered: #505 (comment)
Associated gist https://gist.github.com/zlepper/5d235fa2b5a3cfb396e8e4d15eb362b4

Possible Solution:

We should consider moving to the prettier node api https://prettier.io/docs/en/api.html#prettierformatsource-options.

bcabanes added a commit to bcabanes/nx that referenced this issue Aug 21, 2018
This modify the format command by using the Prettier node API to format files.
No matter how many files there is, it should be able to format them all without crashing.

close nrwl#511
bcabanes added a commit to bcabanes/nx that referenced this issue Aug 21, 2018
This modify the format command by using the Prettier node API to format files.
No matter how many files there is, it should be able to format them all without crashing.

close nrwl#511
bcabanes added a commit to bcabanes/nx that referenced this issue Aug 21, 2018
This modify the format command by using the Prettier node API to format files.
No matter how many files there is, it should be able to format them all without crashing.

close nrwl#511
bcabanes added a commit to bcabanes/nx that referenced this issue Aug 21, 2018
This modify the format command by using the Prettier node API to format files.
No matter how many files there is, it should be able to format them all without crashing.

close nrwl#511
bcabanes added a commit to bcabanes/nx that referenced this issue Aug 22, 2018
The format command now splits all the array containing all the urls and patterns given, in smaller chunks arrays, executing the command on each chunks. This prevent to have too long argument on the command for the terminal, which can lead to error on specific OS. The chaining of command is transparent for the user.

close nrwl#511
bcabanes added a commit to bcabanes/nx that referenced this issue Aug 22, 2018
The format command now splits all the array containing all the urls and patterns given, in smaller chunks arrays, executing the command on each chunks. This prevent to have too long argument on the command for the terminal, which can lead to error on specific OS. The chaining of command is transparent for the user.

close nrwl#511
bcabanes added a commit to bcabanes/nx that referenced this issue Aug 23, 2018
The format command now splits all the array containing all the urls and patterns given, in smaller chunks arrays, executing the command on each chunks. This prevent to have too long argument on the command for the terminal, which can lead to error on specific OS. The chaining of command is transparent for the user.

close nrwl#511
vsavkin pushed a commit that referenced this issue Aug 23, 2018
The format command now splits all the array containing all the urls and patterns given, in smaller chunks arrays, executing the command on each chunks. This prevent to have too long argument on the command for the terminal, which can lead to error on specific OS. The chaining of command is transparent for the user.

close #511
@github-actions
Copy link

This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context.

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

Successfully merging a pull request may close this issue.

2 participants