https://pantsbuild.org/ logo
#general
Title
# general
h

high-yak-85899

05/11/2023, 5:25 PM
Why does
./pants fmt
log a warning when changes are made? Isn't that point of running formatters?
h

happy-kitchen-89482

05/11/2023, 5:28 PM
Yeah, I could go either way. It should probably be INFO, not WARN?
h

high-yak-85899

05/11/2023, 5:30 PM
Yeah, that's what I was thinking. Preference we have internally is to not condition folks to "nominal" warnings.
b

busy-vase-39202

05/11/2023, 5:37 PM
WARN
definitely implies "a problem you need to be aware of" to me. For expected behavior,
INFO
does seem more appropriate. This has a bunch of interesting takes, and seem all to lean toward
INFO
as most befitting this kind of situation.
h

happy-kitchen-89482

05/11/2023, 5:41 PM
a PR to that effect would be very welcome! 🙂
h

high-yak-85899

05/11/2023, 5:51 PM
Also, how is this possible?
fmt
says it made changes while
git status
shows nothing?
Copy code
11:45:13.64 [WARN] Completed: Format with isort - isort made changes.
  <a bunch of files here>

+ isort made changes.
(3.8.10) ~/devel/monorepo (isort)$ gs
On branch isort
Your branch is ahead of 'master' by 2 commits.
  (use "git push" to publish your local commits)

nothing to commit, working tree clean
b

bitter-ability-32190

05/11/2023, 5:52 PM
One formatter changes it one way, another changes it back
h

high-yak-85899

05/11/2023, 5:59 PM
I ran
--only=isort
for this
🤯 2
b

broad-processor-92400

05/11/2023, 8:44 PM
I sometimes see what seems like “stale” output, if a previous run made changes… not sure why. Maybe that’s what you’re hitting too
h

high-yak-85899

05/12/2023, 11:22 PM
a PR to that effect would be very welcome!
This one should be easy enough for me to tackle. I'll try to make it happen this weekend.
❤️ 1
b

busy-vase-39202

05/12/2023, 11:27 PM
Cool, thank you!
2 Views