Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docs: Add more information on migrating from legacy aiida-core #163

Merged
merged 1 commit into from
Oct 11, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 28 additions & 2 deletions docs/source/howto.rst
Original file line number Diff line number Diff line change
Expand Up @@ -142,8 +142,34 @@ where ``<STRINGENCY>`` is a string that defines the recommended cutoffs, ``<FAMI
Migrate from legacy ``UpfData`` from ``aiida-core``
---------------------------------------------------

Since the earliest versions, ``aiida-core`` provided its own data plugin to support UPF pseudopotentials as well as a concept of a pseudopotential family.
The ``UpfData`` from ``aiida-core`` and related utilities are now deprecated and are replaced by ``aiida-pseudo``.
Since the earliest versions, ``aiida-core`` provided its own data plugin ``UpfData`` (with the entry point ``core.upf``) to support UPF pseudopotentials as well as a concept of a pseudopotential family.
That ``aiida.orm.nodes.data.upf`` module which defined the ``UpfData`` class and the ``verdi data core.upf`` command of ``aiida-core`` are now deprecated.
This migration guide provides instructions how to replace the deprecated functionality with ``aiida-pseudo``.

``UpfData``
...........

The ``UpfData`` class is replaced by the class of the same name from the ``aiida-pseudo`` package.
The import ``from aiida.orm.nodes.data.upf import UpfData`` can be replaced by ``from aiida_pseudo.data.pseudo import UpfData``.
The constructor of the two classes is almost identical, so this should be a drop-in replacement.

``verdi data core.upf``
.......................

==================================== ===============================
Deprecated Replacement
==================================== ===============================
``verdi data core.upf uploadfamily`` ``aiida-pseudo install family``
``verdi data core.upf listfamilies`` ``aiida-pseudo list``
``verdi data core.upf exportfamily`` Not yet implemented
``verdi data core.upf import`` Not yet implemented
``verdi data core.upf export`` Not yet implemented
==================================== ===============================


Migrating existing families
...........................

To migrate an existing UPF family from ``aiida-core``, use the following snippet:

.. code-block:: python
Expand Down
Loading