Distillery upgrade fails with cannot run release_utils.escript error

I’m following the Distillery release and hot upgrade from the Programming Elixir 1.6 book. Running on Erlang 20 erts-9.2 64-bits on Windows 7, with Elixir 1.6.

I packaged a release and started it in console view. When I make changes, build a new release and try to do an upgrade, the generated script fails with the following error:

escript failed to open file /bin/release_utils.escript

Process:
> mix release.init
> mix release --env=prod
# unzip tar.gz release 0.1.0 into a separate folder
> bin/sequence console

# make some changes
> mix release --env=prod --upgrade
# move tar.gz release 0.2.0 into corresponding folder
> bin/sequence upgrade 0.2.0
escript failed to open file /bin/release_utils.escript

It closes my MS-DOS window too, had to video capture it to be able to read the error message.

Checking file access with Process Monitor, I see it tries to find the release_utils.escript in C:\bin\release_utils.escript instead of searching in the local folder.

It looks like a bug, but before I raise an issue I wanted to check with the community, in case I’m doing something wrong.

Definitely a bug, can you open an issue? Thanks!

1 Like

https://github.com/bitwalker/distillery/issues/391