Closed jwhite242 closed 1 year ago
Hi @jwhite242 would like to test this and then get it merged. But it is on a fork or something rather than a branch. I know how to 'rebase' or 'merge' to main from branches. But do not know the method for doing so from a fork. Can you get this updated so we can test it. In particular, there are some line conflicts with the current repo 'main' branch that I noticed when I did a simple xxdiff of this file and the main branch. We need to keep the 'main' branch code but get this MR rebased or merged with it.
This PR enables finding machines installed using setuptools' entry points plugin mechanism:
Sample toml file in a project with these machines (note project/package name is a dummy and not real):
This will register the MyAtsSlurmProcessorScheduled custom machine as a plugin names 'my_slurm_proc_sched', which are found within importlib.metadata.entry_points(). These get installed into known groups that the machine import knows to look for, which is currently called 'ats.machines'.
Note, this does not address the separate config issue, using -1 as the default for the constructor of the actual base machine object inherited from. Our wrapper overrides this in our config anyway so this default works fine, but longer term I think this would pair quite well with a separate config as input type approach rather than having such cluster specific config/init settings baked into the machine source files using that custom header comment; as a bonus there'd be much less code churn to adapt to new clusters.
Jeremy