feat: Deploy app directories with priv/ for proper Application.app_dir#16
feat: Deploy app directories with priv/ for proper Application.app_dir#16
Conversation
Deploy entire app-version/ directories instead of flat ebin/ so that Application.app_dir/1 works on the remote and deps can find their priv/ files (e.g. llm_db's database). Update -pa to */ebin glob. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 35cddc0e54
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| # Include app code + Elixir stdlib paths | ||
| pa_paths = [ | ||
| "#{dest}/ebin", | ||
| "#{dest}/*/ebin", |
There was a problem hiding this comment.
Avoid loading stale releases via wildcard code path
Using "#{dest}/*/ebin" adds every previously deployed app directory under dest to the remote VM code path. Since deployment still does tar xzf ... -C #{dest} without clearing old content, re-running replication in the same sandbox after an app/dependency version bump leaves older app-vsn directories present, so the node can resolve modules from stale versions depending on path ordering. This regression is introduced by the wildcard -pa change; either clean dest before extract or build pa_paths from only the just-deployed directories.
Useful? React with 👍 / 👎.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Deploy entire app-version/ directories instead of flat ebin/ so that Application.app_dir/1 works on the remote and deps can find their priv/ files (e.g. llm_db's database). Update -pa to */ebin glob.