Stacks

Upgrade a Dependency and Fix Breakage in Elixir with Atlas in 2026

Updated 7 min read

In 2026, Elixir developers leverage Atlas to upgrade dependencies and fix breakage by automating the entire process from `mix.exs` updates to resolving compile and test failures. Atlas drives `Mix and Hex` to bump versions, reads `mix test` output for errors, and uses its `edit` tool to repair code, ensuring a smooth migration within your Elixir project.

How does Atlas upgrade Elixir dependencies and fix code?

Atlas in 2026 streamlines Elixir dependency upgrades by directly interacting with `Mix and Hex` to update `mix.exs` files. This process begins with Atlas running `mix deps.update` and then systematically addressing any resulting compile or test failures.

Atlas manages Elixir dependency upgrades by leveraging its `bash` tool to execute standard `Mix and Hex` commands. When an Elixir developer requests a dependency bump, Atlas will run `mix deps.update <dependency_name>` or directly modify the `mix.exs` file to specify a new major version. The full output from these `bash` commands is captured; if it exceeds terminal limits, Atlas saves it to a file that can be read with its `read` tool. This ensures Atlas has the complete context of the upgrade process, including any initial warnings or errors from `Mix and Hex`. Atlas does not assume what broke; instead, it reads the real compiler output from subsequent `mix compile` runs to identify and address specific breakage, ensuring fixes are precise and relevant to the actual issues in the Elixir codebase.

How does Atlas identify and fix Elixir compile and test failures?

Atlas identifies breakage in Elixir projects by executing `mix compile` and `mix test` via its `bash` tool, capturing the exact error messages. In 2026, Atlas then uses its `edit` tool to apply precise fixes, guided by the compiler output and `lsp` for new function signatures.

To identify breakage, Atlas uses its `bash` tool to run `mix compile` and `ExUnit via mix test`, capturing all output. This direct interaction with the Elixir toolchain means Atlas works with real compiler errors and test failures, not a simulated environment. Once errors are identified, Atlas employs its `edit` tool to modify the Elixir source code. For instance, if a function signature has changed in an upgraded library, Atlas can use the `lsp` tool's `goToDefinition` operation to inspect the new signature within the upgraded package. This allows Atlas to understand the required changes and apply them accurately to the Elixir code. Atlas iteratively re-runs `mix compile` and `mix test` after each set of fixes until the project compiles cleanly and all tests pass, ensuring a robust and functional Elixir application.

How does Atlas use release notes for Elixir dependency migrations?

For major Elixir dependency upgrades, Atlas in 2026 employs its `webfetch` tool to retrieve the library's release notes and changelogs. This ensures that fixes align precisely with documented breaking changes, preventing guesswork and improving the accuracy of code modifications.

When an Elixir dependency undergoes a major version bump, understanding the breaking changes is crucial. Atlas addresses this by using its `webfetch` tool to pull the release notes, changelogs, or migration guides directly from the library's official sources. This capability provides Atlas with the necessary context to understand *why* certain code patterns are now failing, rather than just *what* is failing. For example, if a library's changelog for its 2026 release details a renamed module or a deprecated function, Atlas can use this information to inform its `edit` tool. This ensures that the fixes applied to the Elixir codebase are not just syntactically correct but also semantically aligned with the new version's API, leading to more stable and maintainable code after the migration.

How does Atlas ensure safety and review for Elixir code changes?

Atlas ensures safety and transparency in Elixir code upgrades through a multi-stage approval process, including a read-only plan agent and unified diffs. Every file edit, from `mix.exs` to application code, is presented for user approval before being written, providing full control over the 2026 migration.

Safety and developer control are paramount in Atlas's workflow for Elixir dependency upgrades. Before any modifications are made, Atlas drafts a plan in a read-only plan agent, allowing the developer to review the proposed strategy. Every Atlas tool call, including `bash` commands for `Mix and Hex` or `edit` operations on Elixir source files, is permission-gated against allow, ask, and deny rules. This means developers explicitly approve actions. Crucially, Atlas computes a unified diff for every file edit it proposes, whether it's a change to `mix.exs`, a `.ex` file, or a test case. These diffs are surfaced for approval, giving the Elixir developer a clear, granular view of every change before it is written to disk. Atlas also reads git branches, status, and diffs, and can stage and create commits on your behalf, ensuring a clean version control history. Furthermore, Atlas snapshots file changes as git patches, allowing edits to be easily diffed and rolled back if needed, providing an additional layer of safety for your Elixir project.

Step by step

  1. 01Run `atlas` in your Elixir project directory containing `mix.exs` to initialize the agent.
  2. 02Ask Atlas to "Upgrade `my_dependency` to version `X.Y.Z`" using `bash` to execute `mix deps.update my_dependency`.
  3. 03Instruct Atlas to `webfetch` the release notes for `my_dependency` from its official documentation or GitHub page.
  4. 04Tell Atlas to "Compile the Elixir project" using `bash` to run `mix compile` and capture all compiler errors.
  5. 05For each compile error reported, ask Atlas to "Fix this error" using its `edit` tool, leveraging `lsp`'s `goToDefinition` to inspect new function signatures in the upgraded package.
  6. 06After addressing compile errors, instruct Atlas to "Run all Elixir tests" using `bash` to execute `ExUnit via mix test`.
  7. 07For any failing tests, ask Atlas to "Fix this test failure" using `edit`, referencing the test output and the `webfetch`'d changelog for context.
  8. 08Repeat the cycle of compiling with `mix compile` and testing with `ExUnit via mix test` via `bash` until the Elixir project is clean.
  9. 09Review the unified diff of all proposed changes presented by Atlas before approving and writing the files to your Elixir codebase.
  10. 10Ask Atlas to stage and commit the changes, creating a new git commit for the completed dependency upgrade.

Frequently asked questions

How does Atlas handle `mix.exs` dependency version updates?
Atlas uses its `bash` tool to directly execute `mix deps.update` or modify `mix.exs` entries, ensuring `Mix and Hex` manages the dependency versions as expected by Elixir developers. This provides a familiar and reliable upgrade path.
Can Atlas fix compile errors from a major Elixir library upgrade?
Yes, Atlas reads the exact output from `mix compile` via `bash`, then uses its `edit` tool, often with `lsp`'s `goToDefinition`, to fix each specific compile error in your Elixir codebase, adapting to new API changes.
How does Atlas ensure Elixir test suites pass after an upgrade?
Atlas repeatedly runs `ExUnit via mix test` using `bash`, identifies failing tests from the output, and then employs its `edit` tool to repair the test code or the application code causing the failures, ensuring full test coverage.
What if the Elixir dependency upgrade introduces complex breaking changes?
Atlas uses `webfetch` to retrieve the dependency's release notes or changelog, providing crucial context for complex breaking changes. This information guides the `edit` tool in applying accurate and informed fixes to your Elixir code.
Is it safe to let Atlas modify my Elixir project files?
Yes, Atlas operates with a read-only plan agent first, and every proposed file edit, including those in `mix.exs` or `.ex` files, is presented as a unified diff for your explicit approval before being written, giving you full control.
Can Atlas help with `mix format` after an Elixir upgrade?
While Atlas focuses on functional fixes, it can execute `mix format` via its `bash` tool to ensure code style consistency across your Elixir project after modifications, maintaining your team's coding standards.
How does Atlas integrate with my existing Elixir development workflow?
Atlas is terminal-native and integrates by driving your existing Elixir toolchain (`Mix and Hex`, `ExUnit via mix test`, `mix format`) through `bash`, reading real outputs, and proposing changes for your review, fitting direct into your daily work.

Try Atlas in your terminal

The terminal-native AI coding agent. Free core, single binary.

Install Atlas

Related guides

Upgrade a Dependency and Fix the Breakage with Atlas (2026 Workflow)

How to upgrade a dependency and fix the breakage with Atlas in 2026: bash drives the package manager, webfetch pulls the release notes, edit fixes each compiler error.

Atlas for Elixir in 2026

Adopt Atlas, the terminal-native AI coding agent, for Elixir development in 2026. Enhance productivity with deep code understanding, safety features, and direct integration into mix projects and OTP applications.

Diagnose a Hanging or Long-Running Elixir Command with Atlas (2026)

When mix test or mix deps.get hangs in Elixir, Atlas tells you whether it is slow or blocked on stdin in 2026, then gets it unstuck with a timeout or a CI flag.

Plan a Multi-File Elixir Change Before Editing with Atlas (2026)

Plan a multi-file Elixir change before editing with Atlas in 2026. Plan mode denies all edit tools, so you research contexts and GenServers and design the change first.

Research a Third-Party API Before Integrating It in Elixir with Atlas (2026)

How to research an external API before writing the Elixir client with Atlas in 2026: websearch, webfetch in markdown, then write the module and run ExUnit via mix test.

Run the Test Suite and Triage the Failures in Elixir with Atlas (2026)

Triage a red ExUnit suite in Elixir with Atlas in 2026. Run mix test through bash, read the retained log past the 2000-line truncation, and group causes with grep.

Trace a Runtime Bug From a Stack Trace in Elixir with Atlas (2026)

Trace an Elixir runtime bug from a stack trace in 2026 with Atlas: read each frame at its offset, grep for the error message, findReferences the callers, fix, add ExUnit.

Automate GitHub Issue and Pull Request Triage in Elixir with Atlas in 2026

Automate GitHub issue and pull request triage in Elixir projects using Atlas. Configure workflows to safely respond to events, ensuring only trusted users trigger actions and reviewing all changes.

Browse this resource hub