Updated my Erlang and Elixir version, my code not working?

I have updated my Erlang and Elixir version and now my code is not working? I have searched for solutions on the Internet but none of them are working. How can I switch back or install the previous version of the Erlang and Elixir? Following version, I want to switch back-

Erlang/OTP 21 [erts-10.3.4]
Elixir (1.8.1)

Your response will be highly appreciated.

How you can return to the previous version depends on how you installed the previous and current versions.

But what is it that doesn’t work with the current versions? Perhaps we can help you fix it, except for some small things like imperative assignment old code should just run on newer versions.

1 Like

Try to delete both _build and deps directories, then use mix deps.get and start the project again. Please share the console log if this doesn’t work.

1- I have deleted the whole folder and again clone the project.
2- run the mix deps.get
3- mix ecto.setup
and this one is generating the error. check the error log. To Note- As mentioned in the screenshot, I have run the cargo update as well but getting the same error.

OTP 21 is supported by rustler for quite a long time now… Are you sure you are using 21?

You still haven’t answered how you installed Erlang. If it’s managed by asdf just switch back to the older versions, if it’s by your systems package manager, you’ll need to consult it’s man pages to see if and how downgrading packages is possible.

See this pic for the Full detail of the version.
Also, I have install the erlang using the sudo apt-get install erlang.

this picture shows OTP 22, not 21 :bulb:

Your initial post says you were using OTP 21…

Anyway, you’ll need to find out how to rollback your version using apt.

I’m not using a Debian derivative anymore for about a year now, and never felt the necessity to rollback a package.


Stack overflow seems to have an answer:

Remember that you want to mainly downgrade Erlang, but other packages might be affected by a downgrade, carefully read the proposed changes before applying, apt sometimes is very eager with removal…

1 Like