tomekowal
Error on incremental compilation in MIX_ENV=test with Elixir 1.19
Hi!
I am trying to pinpoint why my project has issue on incremental compilation when running tests in elixir 1.19.0-rc.0-otp-26
I am running an umbrella project. When I change a file, it triggers recompilation in a couple of apps across umbrella.
I am getting errors like this:
mix deps.compile running across 4 OS processes
4> ==> app1
4> Compiling 1 file (.ex)
4> Generated app1 app
1> ==> app2
1> Compiling 1 file (.ex)
1> Generated app2 app
3> ==> app3
3> Compiling 1 file (.ex)
1> ==> app4
1> Compiling 8 files (.ex)
3> Generated app3 app
1> Generated app4 app
1> ==> app5
1> Compiling 102 files (.ex)
1> Generated app5 app
1> ==> app6
1> Compiling 6 files (.ex)
1> Generated app6 app
** (EXIT from #PID<0.98.0>) an exception was raised:
** (File.Error) could not write to file "/Users/user1/project/_build/test/consolidated/Elixir.Plug.Exception.beam": no such file or directory
(elixir 1.19.0-rc.0) lib/file.ex:1401: File.write!/3
(mix 1.19.0-rc.0) lib/mix/compilers/protocol.ex:159: Mix.Compilers.Protocol.consolidate_each/4
(elixir 1.19.0-rc.0) lib/task/supervised.ex:105: Task.Supervised.invoke_mfa/2
(elixir 1.19.0-rc.0) lib/task/supervised.ex:40: Task.Supervised.reply/4
20:05:54.679 [error] Task #PID<0.902.0> started from #PID<0.98.0> terminating
** (File.Error) could not write to file "/Users/tomaszkowal/bluecodecom/scheme-services-19/_build/test/consolidated/Elixir.Plug.Exception.beam": no such file or directory
(elixir 1.19.0-rc.0) lib/file.ex:1401: File.write!/3
(mix 1.19.0-rc.0) lib/mix/compilers/protocol.ex:159: Mix.Compilers.Protocol.consolidate_each/4
(elixir 1.19.0-rc.0) lib/task/supervised.ex:105: Task.Supervised.invoke_mfa/2
(elixir 1.19.0-rc.0) lib/task/supervised.ex:40: Task.Supervised.reply/4
Function: #Function<8.102399383/0 in Mix.Compilers.Protocol.consolidate/4>
Args: []
...
and then a long list of similarly looking errors for all protocols: Collectable, Phoenix.HTML.Safe and so on and so forth.
This never happened on Elixir 1.18.x or any other previous versions.
I am somewhat sure it is connected to the parallel compilation. Other facts:
- I doesn’t happen always
- it only happens on incremental compilation
- it seems to be pure chance if introducing a new line triggers it or compiles fine
- it only runs in
MIX_ENV=test - when it compiles, subsequent invocation of
mix testwork fine
I wasn’t able to reproduce it outside of our production app, so I don’t have a minimal reproduction example yet that I could share.
Did anybody see anything like that?
Most Liked
Popular in Troubleshooting
Hello everyone,
I’m working on a blockchain project in Elixir and I’m implementing some of the core cryptography in a Rust NIF using Rus...
New
Hi!
I am trying to pinpoint why my project has issue on incremental compilation when running tests in elixir 1.19.0-rc.0-otp-26
I am ru...
New
Besides (over)logging every code-path leading to Repo.insert_all, is it possible to make Postgrex and/or ecto_sql log the exact, failing ...
New
I tried to learn Elixir a few years ago and stopped. I am trying again.
In the code below I have a GenServer that is started by a Superv...
New
I am trying deploy phoenix app to cloud run every thing works locally fine using public IP but when i deployed to cloud run the app could...
New
Hi All,
I am bumping into a weird issue with an umbrella app while upgrading to latest Elixir 1.19.x + otp28.
A couple apps in the umbr...
New
I don’t get an error directly related to Paraxial, but removing that dependency stopped the crash.
Has anyone experienced a similar issu...
New
Hey,
I’ve got a project with several path dependencies. Some are phoenix apps, but this likely isn’t relevant.
I don’t fully understand...
New
Hi,
I have the following code, and even though I can see (via the inspect) that the response_body does contain one of the strings I’m lo...
New
The Issue of Enums in Elixir
Elixir doesn’t have a native enum construct, so we usually rely on atoms, strings, or macros to represent na...
New
Other popular topics
I wanted to check elixir version in phoenix because i found that my elixir is 1.5 but when i use Enum.chunk_by it said the function is un...
New
What’s the safe way to decode a JSON string into a struct? I want to avoid calling String.to_atom. Jason.decode can give me a map with st...
New
As promised, the first release candidate of Phoenix 1.3.0 is out! This release focuses on code generators with improved project structure...
New
Could someone help me? I'm making my first elixir program, number guessing game. I can't figure out how to convert the user's guess from ...
New
ExUnit now has describe blocks which is a welcome addition coming from RSpec. In the docs, it states that nested hierarchies of describe ...
New
I will often find my self writing things similar to:
case some_value do
nil -> something()
"" -> something()
_ -> someth...
New
About me? ( if you have nothing better to do than reading about some random guy in the internet :stuck_out_tongue: )
Hello all, this is ...
New
by Lance Halvorsen
Elixir and Phoenix are generating tremendous excitement as an unbeatable platform for building modern web application...
New
I am trying to run a deploy with docker and I successfully runned with this command:
docker build -t romenigld/blog-prod .
but when I t...
New
Hello again - after a longish gap I’ve decided I really must dig into Elixir and see what’s been happening here - so I have a few questio...
New







