-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
Formatter not loading plugins in subdirectory consistently when run from umbrella root #12880
Comments
I am afraid you have not push the reproduction repo yet. :) |
oh, I accidentally made it private. Should work now |
Possibly another manifestation of the problem. When running from the root
when running from app/backend it works root .formatter
umbrella child .formatter
|
@josevalim I built and installed latest version from 1.15 branch and got this
It stopped crashing after |
That makes sense. We cannot cache anonymous functions. :( I will take another look. |
The issue you saw wouldn’t happen in practice because the Elixir module changed but in practice that would be a new version which would clear all cache. Still, I changed the code that handles sigiles to avoid caching anonymous functions. :) |
Elixir and Erlang/OTP versions
Erlang/OTP 25 [erts-13.2.2.2] [source] [64-bit] [smp:12:12] [ds:12:12:10] [async-threads:1] [jit]
Elixir 1.15.4 (compiled with Erlang/OTP 25)
Operating system
macOS, linux
Current behavior
Repro:
no error
It works consistently if I add
to root
.formatter.exs
Expected behavior
https://hexdocs.pm/mix/main/Mix.Tasks.Format.html#module-formatting-options state about subdirectories:
Nothing about interaction between subdirectories and plugins is stated in plugins section.
My expectation is that running formatter in a subdirectory should be equivalent with running it in root. Moreover, it should behave consistently and not depend on wether
mix clean
has been run.The text was updated successfully, but these errors were encountered: