You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In order to be in line with rules for plugins and to avoid polluting the global namespace, the entry points defined by aiida-core should be prefixed by 'core.', e.g. core.structure.
Just happened to come across this and wanted to mention that core.structure might not be the best example as we might want to move that class to a separate plugin package. core.int, core.float etc. would of course be internal types that would need the prefix
Hmm, forgot about this one. Originally I would have said to coordinate this with the moving out of material science specific plugins to a separate package since that would anyway require entry points to be changed. But maybe we can already preempt this change for the plugins that should stay regardless. I am thinking if we can do this in a backwards-compatible way and deprecate the old entry point names.
We could change the entry point names for internal plugins (Int, Float) etc. to add the core. prefix and add a database migration that updates the node_type from affected nodes, e.g. data.int.Int. would become data.core.init.Int.. This way, after the migration anyone loading a node with data.core.int.Int. would get the correct class back. The only thing that would break in this case (if I am not forgetting anything) is the line
Int = DataFactory('int')
which would have to be changed to
Int = DataFactory('core.int')
However, I think we can deprecate this by having a look up list in the DataFactory that knows about the migrated entry points and in those cases, prints a warning notifying the user of the new entry point name. Then at some point we can remove this and everything should be fine. I think this approach might work and therefore may be interesting to consider adding for v2.0
ltalirz
transferred this issue from aiidateam/aiida-registry
May 5, 2021
In order to be in line with rules for plugins and to avoid polluting the global namespace, the entry points defined by aiida-core should be prefixed by 'core.', e.g.
core.structure
.See also discussion here
Planned for v2.0.0
The text was updated successfully, but these errors were encountered: