← All posts

AiiDA v2.8.0 released

aiida-core

We are happy to announce the release of AiiDA v2.8.0! This minor release brings important improvements to the BaseRestartWorkChain, the engine, stashing, typing coverage, and dependency updates. It also includes several fixes for connection and resource leaks, with further improvements planned for upcoming releases.

As always, the release can be installed from PyPI using pip install aiida-core==2.8.0, or from conda-forge using conda install -c conda-forge aiida-core=2.8.0. For a complete list of changes, see the CHANGELOG.

Behavior changes: This release includes several behavior changes that do not constitute API breaking changes warranting a major version bump, but may still affect existing workflows if you rely on the old defaults. Please review the following list and check the detailed sections below:

  • BaseRestartWorkChain: default on_unhandled_failure changed from restart_once to abort
  • TrajectoryData: new .pbc property; set_trajectory() emits deprecation warning when pbc not specified
  • StructureData.cell_angles now returns None instead of nan for zero-length vectors
  • Portable code executables now include a ./ prefix in job scripts
  • StashCalculation rejects RemoteData from still-running calculations
  • core.ssh_async glob returns an empty list instead of raising an error
  • Transport --safe-interval default changed from 30s to 15s
  • SQLite storage: database lock warning downgraded to INFO level
  • Improved ProcessBuilder representation via print()

Below we highlight the main new features.

BaseRestartWorkChain enhancements

Two new inputs have been added to BaseRestartWorkChain to give users more control over failure handling.

on_unhandled_failure (behavior change): Previously, BaseRestartWorkChain would automatically restart once on unhandled failures. The default is now to abort immediately to save computational resources. To restore the previous behavior, explicitly set on_unhandled_failure='restart_once'. The available options are abort (default), pause, restart_once, and restart_and_pause.

pause_on_max_iterations: A new input that allows the work chain to pause instead of aborting when the maximum iteration limit is reached. This is useful when you want to inspect the calculation state before deciding whether to continue or abort.

Replaced nest_asyncio with greenback

The internal async event loop handling has been refactored to use greenback instead of nest_asyncio (#7206). This drops the deprecated nest_asyncio dependency, provides clearer tracebacks, and enables adding breakpoints in engine modules during development.

Important change for Jupyter notebook users: load_profile() must now be called in a separate cell before running engine processes, as the greenback context is established after the cell containing load_profile() completes.

Unstashing support

Building on the stashing feature introduced in v2.7.0, this release adds unstashing—the ability to retrieve previously stashed data back to the remote working directory (#6826). The new UnstashCalculation (core.unstash) allows you to restore stashed files before running a calculation that needs them. Additionally, RemoteStashCustomData (#6777) enables stashing via custom scripts for specialized data handling needs.

TrajectoryData: periodic boundary conditions support

The TrajectoryData class now properly stores and retrieves periodic boundary conditions (PBC) (#7079). Previously, when creating a trajectory from StructureData instances with specific PBC settings, this information was lost and structures retrieved from a TrajectoryData would always default to (True, True, True). The boundary conditions are now stored in the attributes and can be retrieved using the .pbc property.

Typing improvements

This release significantly expands type annotation coverage across the codebase. Modules including aiida.common, aiida.repository, aiida.schedulers, aiida.tools.graph, aiida.tools.query, aiida.cmdline, and aiida.engine.processes now have strict typing enabled. Plugin developers will benefit from improved autocompletion and type checking when using the AiiDA API.

Dependency updates

AiiDA now supports numpy 2.x (#6899), allowing use of the latest numpy features and performance improvements. The CLI is also now compatible with click 8.2 (#6959).

verdi process repair: orphaned database connection cleanup

When daemon workers crash without proper cleanup, their PostgreSQL connections can remain open, holding locks that block other processes and cause workchains and calcjobs to hang. The verdi process repair command now detects and terminates these orphaned connections (#7207).

Deprecation of core.ssh transport

The core.ssh transport plugin is now deprecated in favor of core.ssh_async (#7175). The async transport offers better performance for concurrent operations and improved configuration through ~/.ssh/config. This release also adds 2FA support for core.ssh_async (#7184).

Happy computing!

The AiiDA team