Skip to content

using a build cache does not prevent always compiling a subset of the files  #12056

@dvic

Description

@dvic

Elixir and Erlang/OTP versions

1.13.4 + OTP 25.0.3

Operating system

linux

Current behavior

When I start a fresh phoenix project, and set up a Github action with a cache for the _build folder that simply compiles the app, there are three files that get recompiled each time (with no source code changes):

  • gettext.ex
  • page_view.ex
  • layout_view.ex

I investigated a bit and the only thing I could find is the following. Locally, when I run twice the mix compile command, the build folder remains exactly the same (I compute the SHA digest using find ./_build -type f -print0 | sort -z | xargs -0 shasum | shasum). However, on Github, the digest of the build folder changes each time and it's in particular because of one file (everything else remains the same):

./_build/dev/lib/gh_debug/.mix/compile.app_tracer

Does this ring any bells? Is this expected behaviour or potentially a bug in the compiler?

Expected behavior

If no source code changed, and I'm using a cache for the _build folder, I expect that no files need to be recompiled (just like it's locally the case).

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions