aiidateam / aiida-core

The official repository for the AiiDA code
https://aiida-core.readthedocs.io
Other
411 stars 184 forks source link

Engine: Set the `to_aiida_type` as default inport port serializer #6439

Closed sphuber closed 3 weeks ago

sphuber commented 4 weeks ago

Fixes #5890

The to_aiida_type serializer automatically converts a number of Python base types to the corresponding Data node when passed as an input to a process. Process functions already automatically set this serializer as a default, which simplifies the life of users and developers.

Here, the to_aiida_type is now set as the default serializer for all input ports. The only exception is if the port is a metadata input port, in which case the data is stored directly in the attributes of the process node and so should not be converted to a node. It is also skipped if the port itself already declares a serializer.

codecov[bot] commented 4 weeks ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 77.70%. Comparing base (ef60b66) to head (255ee56). Report is 20 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #6439 +/- ## ========================================== + Coverage 77.51% 77.70% +0.20% ========================================== Files 560 562 +2 Lines 41444 41726 +282 ========================================== + Hits 32120 32420 +300 + Misses 9324 9306 -18 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.